Skip to content
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
ffcd98d
Initial musing about creation of signing cohort, utilizing a separate…
derekpierre Apr 15, 2025
5c394bd
Minor rename.
derekpierre Apr 15, 2025
b61c1cc
Store SigningCohortParticipants as a list instead of a mapping.
derekpierre Apr 16, 2025
c28b8f7
Add getSigner() function and fix bug where signature was not stored f…
derekpierre Apr 17, 2025
207e960
Use eip191 signing for signing cohort formation.
derekpierre Apr 22, 2025
23fd883
Add the ability to deployer a multisig as part of cohort formation - …
derekpierre Apr 24, 2025
0570525
Be sure to use operator addresses and not provider address for signers.
derekpierre Apr 24, 2025
64a4578
Adjust logic for caching signatures.
derekpierre Apr 25, 2025
0fae651
Signing cohort id is a uint32 (for now), so use it for cohort mapping…
derekpierre Apr 25, 2025
f1afe8a
Ensure that signatures for cohort multisig are unique and that repeat…
derekpierre Apr 25, 2025
718a12c
Obtain data to sign for ritual from contract.
derekpierre Apr 28, 2025
546021f
Limit initiation of signing cohort rituals to only accounts with init…
derekpierre Apr 29, 2025
918ef37
Deploy signing infrastructure contracts to polygon amoy for the lynx …
derekpierre Apr 29, 2025
25d3135
introduces condition storage to the signing cohort struct
KPrasch May 1, 2025
9ad0d30
basic testing for onchain conditions
KPrasch May 1, 2025
4254cf3
signing corrdinator upgrade deployment scripts
KPrasch May 1, 2025
b3137f1
Test cleanup.
derekpierre May 1, 2025
20df5b2
Redeploy SigningCoordinator after trying to upgrade but then storage …
derekpierre May 1, 2025
602bca1
Fix linting for PolygonChile.
derekpierre May 9, 2025
e6a1927
Initial musing about canonical SigningCoordinator contract that can b…
derekpierre May 9, 2025
15dc5db
Initial musing regarding Optimism-based bridged contracts eg. Eth Sep…
derekpierre May 9, 2025
2908cc0
Ensure that ape chain id is properly maintained for tests.
derekpierre May 12, 2025
d2d20d1
Some initial code for managing cohorts across different chains via a …
derekpierre May 12, 2025
ddd4b54
Update tests to account for set up of single signing coordinator, sig…
derekpierre May 12, 2025
0303b13
Rename sender/receiver contracts.
derekpierre May 12, 2025
3f557d9
Establish abstracted interfaces for L1->L2 sender/receiver contracts …
derekpierre May 14, 2025
7941cef
Update implementations of sender/receiver interfaces to match updated…
derekpierre May 14, 2025
3d0b324
Update SigningCoordinator to be able to handle deployment of signing …
derekpierre May 14, 2025
589daf9
Update code for deploying cohort multisigs on other chains.
derekpierre May 14, 2025
e701331
Code cleanup for internal method on SigningCoordinator.
derekpierre May 15, 2025
47b4379
Update SigningCoordinator to use TACoApplication instead of TACoChild…
derekpierre May 15, 2025
c68f1de
Update contracts to follow parent-child dynamic of parent being deplo…
derekpierre May 17, 2025
ebe47c0
Add root and child deployment scripts for signing infrastructure cont…
derekpierre May 17, 2025
17087f6
Don't disable initializers for ThresholdSigningMultisig since it will…
derekpierre May 20, 2025
20620d8
Allow ability to obtain child app address from SigningCoordinator bas…
derekpierre May 20, 2025
b2adee2
Add ability to modify max dkg size and dispatcher contract used by Si…
derekpierre May 21, 2025
c8f5e63
Add ability to modify initialization values afterwards for SigningCoo…
derekpierre May 21, 2025
92609e9
Update function for getUnsignedTransactionHash to use EIP191 standard.
derekpierre May 21, 2025
7360cd0
Apply RFCs from #366.
derekpierre May 22, 2025
e6ac365
Only set conditions for chains that already have multisigs deployed.
derekpierre May 26, 2025
ec420dd
Add SigningCoordinator to contract list exposed to sdk
theref Jun 18, 2025
c0da4a3
Add signing infrastructure root deployment information to the lynx re…
derekpierre May 23, 2025
40bc0b3
Remove unnecessary underscores.
derekpierre May 22, 2025
9901070
Add SigningCoordinator function to extend cohort durations - only the…
derekpierre Jun 25, 2025
90bd925
Add `getThreshold` to SigningCoordinator
theref Jun 18, 2025
fdbd793
Make modifications to OpL2Receiver so that setting the address of L1 …
derekpierre May 23, 2025
6ca8925
Add storage gap.
derekpierre May 22, 2025
55e5243
Upgrade SigningCoordinator on lynx and update contract registry with …
derekpierre Jun 25, 2025
a1328a9
Update scripts for upgrading signing coordinator contract on lynx.
derekpierre Jun 18, 2025
538c519
first draft: form signing cohort scripting
KPrasch Jun 10, 2025
1c17598
Update lynx registry with latest child infra deployments to base.
derekpierre May 23, 2025
2613b84
Apply RFC from #366.
derekpierre May 23, 2025
d2f8bbf
Additional testing for signing coordinator to try to deploy signing c…
derekpierre Jun 26, 2025
4106327
Remove deprecated oryx domain and add sepolia as a possible chain id …
derekpierre Jun 18, 2025
8299bd6
includes condition setting script for signing cohorts
KPrasch Jun 10, 2025
61424c1
Fix bug in child deployment script - allowed caller should be l2 rece…
derekpierre May 26, 2025
b6b4765
Merge pull request #366 from derekpierre/secreto
derekpierre May 23, 2025
8bed9da
Deprecate getCondition in favour of getSigningCohortConditions. Didn'…
derekpierre Jun 27, 2025
9083b57
Adjust tests to be more specific about testing polygon contracts.
derekpierre Jun 18, 2025
1c646e4
respond to RFCs in PR #393
KPrasch Jun 17, 2025
1afcab2
Merge pull request #382 from derekpierre/secreto-deployment
derekpierre May 26, 2025
34bb21a
Remove duplicate getCondition method from SigningCoordinator contract.
derekpierre Jun 27, 2025
aac4cc2
Upgrade SigningCoordinator for lynx which updated contract registry a…
derekpierre Jun 18, 2025
7d65022
Merge pull request #393 from KPrasch/signing-formation
KPrasch Jun 18, 2025
d3646d5
Upgraded deployed SigningCoordinator to remove getCondition function.
derekpierre Jun 27, 2025
0248308
Merge pull request #398 from theref/signingCoordinator
derekpierre Jun 19, 2025
1bd49cd
Allows operator to set signer address
vzotova Oct 15, 2025
e414d9c
Merge pull request #385 from derekpierre/various-updates
derekpierre Jun 27, 2025
c9d25d6
SigningCoordinator: remove `operator` from storage layout
vzotova Oct 21, 2025
ab01b9d
Bump version: 0.25.0 → 0.26.0-alpha.1
derekpierre Aug 5, 2025
8a088aa
SignerCoordinator: Signer has to sign operator address
vzotova Oct 24, 2025
0e58a0a
Update version to 0.26.0-alpha.1 in package-lock.json.
derekpierre Aug 5, 2025
c7ab113
Adds signing request key to the contract state
vzotova Oct 29, 2025
ac07cf8
Ensure that ordering follows contract (checksum as int) and not lexic…
derekpierre Oct 27, 2025
08c176e
Merge pull request #436 from vzotova/operator-signer
derekpierre Oct 27, 2025
6eddbdd
respond to RFCs in PR #438
vzotova Oct 30, 2025
205e7df
Merge pull request #437 from derekpierre/node-ordering
derekpierre Oct 30, 2025
d315bf8
Merge pull request #438 from vzotova/request-key
derekpierre Nov 7, 2025
720cb9b
Relock dependencies using latest from `nucypher-core`.
derekpierre Nov 8, 2025
8ec51dc
Update Dispatcher contract to be proxyable.
derekpierre Nov 8, 2025
3485c46
Update/add scripts for root signing infra - in particular SigningCoor…
derekpierre Nov 8, 2025
df34d71
Update root signing infra information for `lynx` after updated deploy…
derekpierre Nov 9, 2025
54578a6
Update address of Dispatcher used by child signing infra update script.
derekpierre Nov 9, 2025
6a64789
Update child signing infra information in `lynx` contract registry af…
derekpierre Nov 9, 2025
23517ad
Update proxy change to Dispatcher for signing root deploy script.
derekpierre Nov 9, 2025
6762e0a
Fully redeploy child signing infrastructure since old SigningCoordina…
derekpierre Nov 9, 2025
86983b3
Add ability to verify more than one contract in one call.
derekpierre Nov 9, 2025
2e7f5ca
Add script to deploy signing cohort to additional chains if the cohor…
derekpierre Nov 10, 2025
ff57ccb
Bump version to 0.26.0-alpha.2
derekpierre Nov 10, 2025
66fc2dd
Remove scripts for redeploying/updating signing infra. Those scripts …
derekpierre Nov 10, 2025
466eac6
Add isSigner assertions to ThresholdSigningMultisig tests.
derekpierre Nov 12, 2025
b0d56dd
Clean up script.
derekpierre Nov 10, 2025
39722b2
Update SigningCoordinatorDispatcher to ensure l1 sender address is 0-…
derekpierre Nov 12, 2025
3285d85
Add tests for threshold signing multisig contract.
derekpierre Nov 11, 2025
5804859
Merge pull request #441 from derekpierre/new-signing-coordinator
derekpierre Nov 10, 2025
98c3f91
Add tests for SigningCoordinatorChild.
derekpierre Nov 12, 2025
7588451
Merge pull request #442 from derekpierre/multisig-testing
derekpierre Nov 12, 2025
406295c
Merge pull request #443 from derekpierre/more-testing
derekpierre Nov 12, 2025
48273ab
Draft for conditions hierarchy
vzotova Nov 12, 2025
cba3b3a
Adds server id as a parameter
vzotova Nov 17, 2025
5a3f9a9
Allows to set server conditions only if they are signed by cohort
vzotova Dec 1, 2025
84c0de8
Renames server -> domain. Simplifies hash
vzotova Dec 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 38 additions & 2 deletions contracts/contracts/coordination/SigningCoordinator.sol
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ import "@openzeppelin/contracts/utils/cryptography/MessageHashUtils.sol";
import "@openzeppelin-upgradeable/contracts/access/extensions/AccessControlDefaultAdminRulesUpgradeable.sol";
import "@openzeppelin-upgradeable/contracts/proxy/utils/Initializable.sol";
import "./ISigningCoordinatorChild.sol";
import "./SigningCoordinatorChild.sol";
import "./SigningCoordinatorDispatcher.sol";
import "./ThresholdSigningMultisig.sol";
import "../TACoApplication.sol";

// SigningCoordinator ----> Dispatcher ----> (Relevant) L1Sender ---------[BRIDGE]---------- L2Receiver ----> SigningCoordinatorChild (1. deploys multisig OR 2. updates multisig)
Expand Down Expand Up @@ -310,11 +312,25 @@ contract SigningCoordinator is Initializable, AccessControlDefaultAdminRulesUpgr
emit SigningCohortConditionsSet(cohortId, msg.sender, chainId, conditions);
}

function getUnsignedTransactionHash(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"If" we go this route (of getting conditions signed by the cohort), would a similar function to getSigningCohortDataHash(...) (which we use for the ritual) be simpler? I'm particularly worried about the use of nonce and that multisig function. wdyt?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, it can be without nonce similar to getSigningCohortDataHash, but it will open ability to execute same tx twice which in that case should not be big deal

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed nonce and simplified in general

ThresholdSigningMultisig multisig,
address serverAdmin,
uint32 cohortId,
uint256 chainId,
bytes memory conditions,
uint256 serverId
) public view returns (bytes32) {
bytes memory data = abi.encodePacked(cohortId, serverId, chainId, conditions);
uint256 nonce = multisig.nonce();
return multisig.getUnsignedTransactionHash(serverAdmin, address(this), 0, data, nonce);
}

function setSigningCohortConditions(
uint32 cohortId,
uint256 chainId,
bytes calldata conditions,
uint256 serverId
uint256 serverId,
bytes calldata signature
) external {
SigningCohort storage signingCohort = signingCohorts[cohortId];
conditionsCheck(signingCohort, chainId);
Expand All @@ -325,6 +341,26 @@ contract SigningCoordinator is Initializable, AccessControlDefaultAdminRulesUpgr
signingCohort.authority == msg.sender || server.activeServerAdmins[msg.sender],

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean that the cohort authority can override a server admin for setting the serverId-specific condition? If so, I don't think we want to give the cohort authority that power.

Only the server admin can set the serverId-specific condition. (cc @arjunhassard )

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But cohort admin can set itself to server admin anyway, right?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right that technically they can take that route to set a serverid-specific condition.

Typically the cohort admin and server admins should be separate. They may be the same in Collab.Land's Discord server, but shouldn't be for other Discord servers.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed privilege for cohort admin

"Only the cohort authority or a server admin can set conditions"
);

SigningCoordinatorChild child = SigningCoordinatorChild(
getSigningCoordinatorChild(block.chainid)
);
ThresholdSigningMultisig multisig = ThresholdSigningMultisig(
child.cohortMultisigs(cohortId)
);

bytes32 hash = getUnsignedTransactionHash(
multisig,
msg.sender,
cohortId,
chainId,
conditions,
serverId
);
require(
multisig.isValidSignature(hash, signature) == multisig.MAGICVALUE(),
"Invalid Signature"
);
server.conditions[chainId] = conditions;
emit SigningCohortConditionsSet(cohortId, msg.sender, chainId, conditions); // TODO log serverId
}
Expand Down Expand Up @@ -473,7 +509,7 @@ contract SigningCoordinator is Initializable, AccessControlDefaultAdminRulesUpgr
}
}

function getSigningCoordinatorChild(uint256 chainId) external view returns (address) {
function getSigningCoordinatorChild(uint256 chainId) public view returns (address) {
address child = signingCoordinatorDispatcher.getSigningCoordinatorChild(chainId);
return child;
}
Expand Down
4 changes: 2 additions & 2 deletions contracts/contracts/coordination/ThresholdSigningMultisig.sol
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ contract ThresholdSigningMultisig is
address[] public signers;
uint16 public threshold;

bytes4 internal constant MAGICVALUE = 0x1626ba7e;
bytes4 internal constant INVALID_SIGNATURE = 0xffffffff;
bytes4 public constant MAGICVALUE = 0x1626ba7e;
bytes4 public constant INVALID_SIGNATURE = 0xffffffff;
mapping(bytes32 => bytes32) public validSignatures;

/**
Expand Down
Loading