redact ipfs updates
This commit is contained in:
parent
ff7c62af24
commit
6185a5d12a
@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "relayer-penalty-proposal",
|
||||
"name": "audit-reimbursement-remuneration-q2-proposal",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
@ -8,7 +8,7 @@
|
||||
"test": "test"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "forge test -vvvvv --fork-url https://api.securerpc.com/v1 --block-number 17011300"
|
||||
"test": "forge test -vvvvv --fork-url https://api.securerpc.com/v1 --block-number 17060055"
|
||||
},
|
||||
"author": "",
|
||||
"license": "ISC"
|
||||
|
@ -2,36 +2,10 @@ pragma solidity 0.8.1;
|
||||
|
||||
import "@interfaces/ISablier.sol";
|
||||
import "@interfaces/IERC20.sol";
|
||||
import "@interfaces/IENSResolver.sol";
|
||||
import "@interfaces/IENSRegistry.sol";
|
||||
|
||||
contract Proposal {
|
||||
|
||||
function updateENSIPFSConfig() internal {
|
||||
bytes32 ROOT_ENS_NODE = 0xe6ae31d630cc7a8279c0f1c7cbe6e7064814c47d1785fa2703d9ae511ee2be0c;
|
||||
bytes32 ENS_DOCS_LABEL_HASH = 0x6bf9054545420e9e9f4aa4f353a32c7d0d52c11dbcdda56c53be8375cafeebb1;
|
||||
bytes32 ENS_RELAYERS_NETWORK_LABEL_HASH = 0x25e5cde5b364d3ffc5a7c8fecda7cf863701488fc2dd91fb4c9e6c59e62bad4a;
|
||||
bytes32 ENS_RELAYERS_NETWORK_SUBNODE = 0x4e37047f2c961db41dfb7d38cf79ca745faf134a8392cfb834d3a93330b9108d;
|
||||
|
||||
bytes memory ROOT_IPFS_HASH = hex"e301017012209958c2dae126b12afe086fa7397b4af704bbe4e7feda58813932078ecdaf71a3";
|
||||
bytes memory DOCS_IPFS_HASH = hex"e30101701220fe412f995e15573c95e24858e0427816f13632c6aba8751538888d84747baf64";
|
||||
bytes memory RELAYERS_NETWORK_IPFS_HASH = hex"e3010170122019d458d9e82c0e5637fb90f5a0701b273aee8f733691492f870c35517749769b";
|
||||
|
||||
address _resolverAddress = 0x4976fb03C32e5B8cfe2b6cCB31c09Ba78EBaBa41;
|
||||
address _registryAddress = 0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e;
|
||||
address _governanceAddress = 0x5efda50f22d34F262c29268506C5Fa42cB56A1Ce;
|
||||
|
||||
IENSRegistry(_registryAddress).setSubnodeRecord(ROOT_ENS_NODE, ENS_DOCS_LABEL_HASH, _governanceAddress, _resolverAddress, 0);
|
||||
IENSRegistry(_registryAddress).setSubnodeOwner(ROOT_ENS_NODE, ENS_RELAYERS_NETWORK_LABEL_HASH, _governanceAddress);
|
||||
|
||||
bytes32 ENS_DOCS_SUBNODE = IENSRegistry(_registryAddress).setSubnodeOwner(ROOT_ENS_NODE, ENS_DOCS_LABEL_HASH, _governanceAddress);
|
||||
|
||||
IENSResolver(_resolverAddress).setContenthash(ROOT_ENS_NODE, ROOT_IPFS_HASH);
|
||||
IENSResolver(_resolverAddress).setContenthash(ENS_DOCS_SUBNODE, DOCS_IPFS_HASH);
|
||||
IENSResolver(_resolverAddress).setContenthash(ENS_RELAYERS_NETWORK_SUBNODE, RELAYERS_NETWORK_IPFS_HASH);
|
||||
}
|
||||
|
||||
function appendSablierRemuneration() internal {
|
||||
function executeProposal() external {
|
||||
uint256 FISCAL_Q_DURATION = 91 days;
|
||||
uint256 RENUMERATION_START_TS = block.timestamp;
|
||||
uint256 RENUMERATION_AMOUNT = 8131 ether;
|
||||
@ -57,10 +31,5 @@ contract Proposal {
|
||||
);
|
||||
}
|
||||
|
||||
function executeProposal() external {
|
||||
updateENSIPFSConfig();
|
||||
appendSablierRemuneration();
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -1,9 +0,0 @@
|
||||
pragma solidity 0.8.1;
|
||||
|
||||
interface IENSRegistry {
|
||||
|
||||
function setSubnodeOwner(bytes32 node, bytes32 label, address owner) external returns(bytes32);
|
||||
|
||||
function setSubnodeRecord(bytes32 node, bytes32 label, address owner, address resolver, uint64 ttl) external;
|
||||
|
||||
}
|
@ -1,9 +0,0 @@
|
||||
pragma solidity 0.8.1;
|
||||
|
||||
interface IENSResolver {
|
||||
|
||||
function setContenthash(bytes32 node, bytes memory hash) external;
|
||||
|
||||
function contenthash(bytes32 node) external returns (bytes memory);
|
||||
|
||||
}
|
@ -9,7 +9,7 @@ contract Mock {
|
||||
|
||||
uint256 constant PROPOSAL_DURATION = 7 days;
|
||||
uint256 constant PROPOSAL_THRESHOLD = 25000 ether;
|
||||
string constant PROPOSAL_DESCRIPTION = "{title:'Proposal #17: Remuneration and ENS IPFS updates',description:''}";
|
||||
string constant PROPOSAL_DESCRIPTION = "{title:'Proposal #16: Audit Reimbursement and remuneration Q2',description:''}";
|
||||
|
||||
address constant VERIFIER_ADDRESS = 0x77777FeDdddFfC19Ff86DB637967013e6C6A116C;
|
||||
|
||||
|
@ -2,7 +2,6 @@ pragma solidity ^0.8.1;
|
||||
|
||||
contract Parameters {
|
||||
|
||||
// Remuneration
|
||||
uint256 FISCAL_Q_DURATION = 91 days;
|
||||
uint256 RENUMERATION_START_TS = block.timestamp;
|
||||
uint256 RENUMERATION_AMOUNT = 8131 ether;
|
||||
@ -12,22 +11,9 @@ contract Parameters {
|
||||
|
||||
uint256 AUDIT_REMMINBURSEMENT_AMOUNT = 1802 ether;
|
||||
|
||||
// ENS IPFS configuration
|
||||
bytes32 ROOT_ENS_NODE = 0xe6ae31d630cc7a8279c0f1c7cbe6e7064814c47d1785fa2703d9ae511ee2be0c;
|
||||
bytes32 ENS_DOCS_SUBNODE = 0xd7b8aac14a9b2507ab99b5fde3060197fddb9735afa9bf38b1f7e34923cb935e;
|
||||
bytes32 ENS_RELAYERS_NETWORK_SUBNODE = 0x4e37047f2c961db41dfb7d38cf79ca745faf134a8392cfb834d3a93330b9108d;
|
||||
bytes32 ENS_RELAYERS_NETWORK_LABEL_HASH = 0x25e5cde5b364d3ffc5a7c8fecda7cf863701488fc2dd91fb4c9e6c59e62bad4a;
|
||||
bytes32 ENS_DOCS_LABEL_HASH = 0x6bf9054545420e9e9f4aa4f353a32c7d0d52c11dbcdda56c53be8375cafeebb1;
|
||||
|
||||
bytes ROOT_IPFS_HASH = hex"e301017012209958c2dae126b12afe086fa7397b4af704bbe4e7feda58813932078ecdaf71a3";
|
||||
bytes DOCS_IPFS_HASH = hex"e30101701220fe412f995e15573c95e24858e0427816f13632c6aba8751538888d84747baf64";
|
||||
bytes RELAYERS_NETWORK_IPFS_HASH = hex"e3010170122019d458d9e82c0e5637fb90f5a0701b273aee8f733691492f870c35517749769b";
|
||||
|
||||
// Beneficary addresses
|
||||
address public _governanceAddress = 0x5efda50f22d34F262c29268506C5Fa42cB56A1Ce;
|
||||
address public _tokenAddress = 0x77777FeDdddFfC19Ff86DB637967013e6C6A116C;
|
||||
address public _sablierAddress = 0xCD18eAa163733Da39c232722cBC4E8940b1D8888;
|
||||
address public _registryAddress = 0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e;
|
||||
address public _resolverAddress = 0x4976fb03C32e5B8cfe2b6cCB31c09Ba78EBaBa41;
|
||||
|
||||
}
|
@ -2,7 +2,6 @@ pragma solidity ^0.8.1;
|
||||
|
||||
import "@interfaces/IGovernance.sol";
|
||||
import "@interfaces/IERC20.sol";
|
||||
import "@interfaces/IENSResolver.sol";
|
||||
|
||||
import "@proprietary/Parameters.sol";
|
||||
import "@proprietary/Mock.sol";
|
||||
@ -78,15 +77,7 @@ contract ProposalTest is Test, Parameters, Mock {
|
||||
/* ----------------------------*/
|
||||
}
|
||||
|
||||
function compareBytes(bytes memory a, bytes memory b) public returns (bool e) {
|
||||
e = keccak256(abi.encodePacked(a)) == keccak256(abi.encodePacked(b));
|
||||
}
|
||||
|
||||
function checkParameters() internal {}
|
||||
|
||||
function checkResults() internal {
|
||||
require(compareBytes(IENSResolver(_resolverAddress).contenthash(ROOT_ENS_NODE), ROOT_IPFS_HASH));
|
||||
require(compareBytes(IENSResolver(_resolverAddress).contenthash(ENS_DOCS_SUBNODE), DOCS_IPFS_HASH));
|
||||
require(compareBytes(IENSResolver(_resolverAddress).contenthash(ENS_RELAYERS_NETWORK_SUBNODE), RELAYERS_NETWORK_IPFS_HASH));
|
||||
}
|
||||
function checkResults() internal {}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user