Update governance implementation address on ENS domain governance-impl.contract.tornadocash.eth
This commit is contained in:
parent
b7ea254974
commit
322b463917
@ -1,9 +1,11 @@
|
||||
bytes32 rootTornadoENSNode = 0xe6ae31d630cc7a8279c0f1c7cbe6e7064814c47d1785fa2703d9ae511ee2be0c;
|
||||
bytes32 tornadoContractENSNode = 0xe7e1d618367ebadd8e172150a43cfc839fd19022c2be81a6e8d45e06aa1011cd;
|
||||
bytes32 stakingRewardsENSNode = 0x3da4b79cd8c20d2fafb1c7cb37a62be8668f543393f6636d421fba0be735e68f;
|
||||
bytes32 governanceImplENSNode = 0x092359a5505072470ce8b86eebed5b4b6f001fe6bd08dbcf723c97073a360cfc;
|
||||
bytes32 novaENSNode = 0xc3964c598b56aeaee4c253283fb1ebb12510b95db00960589cdc62807a2537a0;
|
||||
bytes32 docsENSNode = 0xd7b8aac14a9b2507ab99b5fde3060197fddb9735afa9bf38b1f7e34923cb935e;
|
||||
bytes32 relayersUIENSNode = 0x4e37047f2c961db41dfb7d38cf79ca745faf134a8392cfb834d3a93330b9108d;
|
||||
|
||||
bytes32 tornadoContractENSLabelhash = 0x7f6dd79f0020bee2024a097aaa5d32ab7ca31126fa375538de047e7475fa8572;
|
||||
bytes32 stakingRewardsENSLabelhash = 0x15826fcf9999635849b273bcd226f436dc42a8fabf43049b60971ab51d8d6b8f;
|
||||
bytes32 governanceImplENSLabelhash = 0x6583a22765d3d6a6ca97b21440f79fecaf21bb8bcaa4fb694483e63d821ba50d;
|
||||
|
@ -8,6 +8,7 @@ import { DeclCalculator } from "./utils";
|
||||
|
||||
const rootTornadoDomain = "tornadocash.eth";
|
||||
const stakingDomain = "staking-rewards.contract.tornadocash.eth";
|
||||
const governanceImplDomain = "governance-impl.contract.tornadocash.eth";
|
||||
const novaUIDomain = "nova.tornadocash.eth";
|
||||
const docsDomain = "docs.tornadocash.eth";
|
||||
const relayersUIDomain = "relayers-network.tornadocash.eth";
|
||||
@ -16,6 +17,7 @@ const tornadoContractDomain = "contract.tornadocash.eth";
|
||||
const rootTornadoENSNode = hash(rootTornadoDomain);
|
||||
const tornadoContractENSNode = hash(tornadoContractDomain);
|
||||
const stakingRewardsENSNode = hash(stakingDomain);
|
||||
const governanceImplENSNode = hash(governanceImplDomain);
|
||||
const novaENSNode = hash(novaUIDomain);
|
||||
const docsENSNode = hash(docsDomain);
|
||||
const relayersUIENSNode = hash(relayersUIDomain);
|
||||
@ -23,17 +25,20 @@ const relayersUIENSNode = hash(relayersUIDomain);
|
||||
const getLabelhashFromDomain = (ensDomain: string) => "0x" + keccak_256(ensDomain.split(".")[0]);
|
||||
const tornadoContractENSLabelhash = getLabelhashFromDomain(tornadoContractDomain);
|
||||
const stakingRewardsENSLabelhash = getLabelhashFromDomain(stakingDomain);
|
||||
const governanceImplENSLabelhash = getLabelhashFromDomain(governanceImplDomain);
|
||||
|
||||
const { calculateDecl } = new DeclCalculator("bytes32");
|
||||
const solidityCode =
|
||||
calculateDecl({ rootTornadoENSNode }) +
|
||||
calculateDecl({ tornadoContractENSNode }) +
|
||||
calculateDecl({ stakingRewardsENSNode }) +
|
||||
calculateDecl({ governanceImplENSNode }) +
|
||||
calculateDecl({ novaENSNode }) +
|
||||
calculateDecl({ docsENSNode }) +
|
||||
calculateDecl({ relayersUIENSNode }) +
|
||||
"\n" +
|
||||
calculateDecl({ tornadoContractENSLabelhash }) +
|
||||
calculateDecl({ stakingRewardsENSLabelhash });
|
||||
calculateDecl({ stakingRewardsENSLabelhash }) +
|
||||
calculateDecl({ governanceImplENSLabelhash });
|
||||
|
||||
fs.writeFileSync(path.join("data", "ensNodesDeclarations.txt"), solidityCode);
|
||||
|
@ -12,6 +12,7 @@ contract UpdateENSDataProposal is TornadoAddresses {
|
||||
function executeProposal() public {
|
||||
address ensResolverAddress = 0x4976fb03C32e5B8cfe2b6cCB31c09Ba78EBaBa41;
|
||||
address ensRegistryAddress = 0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e;
|
||||
address governanceImplementationAddress = 0xBa178126C28F50Ee60322a82f5EbCd6b3711e101;
|
||||
|
||||
IENSRegistry ensRegistry = IENSRegistry(ensRegistryAddress);
|
||||
IENSResolver ensResolver = IENSResolver(ensResolverAddress);
|
||||
@ -20,19 +21,25 @@ contract UpdateENSDataProposal is TornadoAddresses {
|
||||
bytes32 rootTornadoENSNode = 0xe6ae31d630cc7a8279c0f1c7cbe6e7064814c47d1785fa2703d9ae511ee2be0c;
|
||||
bytes32 tornadoContractENSNode = 0xe7e1d618367ebadd8e172150a43cfc839fd19022c2be81a6e8d45e06aa1011cd;
|
||||
bytes32 stakingRewardsENSNode = 0x3da4b79cd8c20d2fafb1c7cb37a62be8668f543393f6636d421fba0be735e68f;
|
||||
bytes32 governanceImplENSNode = 0x092359a5505072470ce8b86eebed5b4b6f001fe6bd08dbcf723c97073a360cfc;
|
||||
bytes32 novaENSNode = 0xc3964c598b56aeaee4c253283fb1ebb12510b95db00960589cdc62807a2537a0;
|
||||
bytes32 docsENSNode = 0xd7b8aac14a9b2507ab99b5fde3060197fddb9735afa9bf38b1f7e34923cb935e;
|
||||
bytes32 relayersUIENSNode = 0x4e37047f2c961db41dfb7d38cf79ca745faf134a8392cfb834d3a93330b9108d;
|
||||
|
||||
bytes32 tornadoContractENSLabelhash = 0x7f6dd79f0020bee2024a097aaa5d32ab7ca31126fa375538de047e7475fa8572;
|
||||
bytes32 stakingRewardsENSLabelhash = 0x15826fcf9999635849b273bcd226f436dc42a8fabf43049b60971ab51d8d6b8f;
|
||||
bytes32 governanceImplENSLabelhash = 0x6583a22765d3d6a6ca97b21440f79fecaf21bb8bcaa4fb694483e63d821ba50d;
|
||||
|
||||
// At first change owner of subdomain contract.tornadocash.eth and then staking-rewards.contract.tornadocash.eth to Governance
|
||||
// At first change owner of subdomain contract.tornadocash.eth and then staking-rewards.contract.tornadocash.eth
|
||||
// and governance-impl.contract.tornadocash.eth to Governance
|
||||
ensRegistry.setSubnodeOwner(rootTornadoENSNode, tornadoContractENSLabelhash, governanceAddress);
|
||||
ensRegistry.setSubnodeOwner(tornadoContractENSNode, stakingRewardsENSLabelhash, governanceAddress);
|
||||
ensRegistry.setSubnodeOwner(tornadoContractENSNode, governanceImplENSLabelhash, governanceAddress);
|
||||
|
||||
// Update staking address, that has been changed in proposal 22: https://tornado.ws/governance/22
|
||||
ensResolver.setAddr(stakingRewardsENSNode, stakingAddress);
|
||||
// Update Governance implementation (logic) address on ENS, that has been changed in proposal 22: https://tornado.ws/governance/22
|
||||
ensResolver.setAddr(governanceImplENSNode, governanceImplementationAddress);
|
||||
|
||||
// From data/ensDomainsIPFSContenthashes.txt, calculated via scripts/calculateIPFSContenthashes.ts
|
||||
bytes memory classicUiIPFSContenthash = hex"e301017012203c89ba6bfdeb8d7209463006e620ee6dcb34675cf3202f20919e3a5f9919070d";
|
||||
|
Loading…
Reference in New Issue
Block a user