diff --git a/.changeset/eighty-signs-help.md b/.changeset/eighty-signs-help.md new file mode 100644 index 0000000000..cf3fd4777a --- /dev/null +++ b/.changeset/eighty-signs-help.md @@ -0,0 +1,5 @@ +--- +"@hashgraph/asset-tokenization-contracts": major +--- + +emegency replacement table added to BLR and resolveResolverProxyCall updated. Proxy storage also updated to fit configuraiton into a single bytes data type. V1 of Proxy Resolver and previous resolverResolverProxyCall method kept for retrocompatibility reasons diff --git a/docs/ats/api/contracts/domain/orchestrator/ClearingProtectedOps.md b/docs/ats/api/contracts/domain/orchestrator/ClearingProtectedOps.md index cca2e1259f..9e08064ef9 100644 --- a/docs/ats/api/contracts/domain/orchestrator/ClearingProtectedOps.md +++ b/docs/ats/api/contracts/domain/orchestrator/ClearingProtectedOps.md @@ -26,6 +26,20 @@ _The caller must provide and validate deadlines before accepting the signed oper | -------- | ------- | ----------------------------------------------- | | deadline | uint256 | Expired deadline carried by the signed payload. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/domain/orchestrator/HoldOps.md b/docs/ats/api/contracts/domain/orchestrator/HoldOps.md index c16c9151d6..01b04dbea3 100644 --- a/docs/ats/api/contracts/domain/orchestrator/HoldOps.md +++ b/docs/ats/api/contracts/domain/orchestrator/HoldOps.md @@ -291,6 +291,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WrongNonce ```solidity diff --git a/docs/ats/api/contracts/domain/orchestrator/TokenCoreOps.md b/docs/ats/api/contracts/domain/orchestrator/TokenCoreOps.md index cb9b473deb..c109b5f149 100644 --- a/docs/ats/api/contracts/domain/orchestrator/TokenCoreOps.md +++ b/docs/ats/api/contracts/domain/orchestrator/TokenCoreOps.md @@ -291,6 +291,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WrongNonce ```solidity diff --git a/docs/ats/api/contracts/facets/IAsset.md b/docs/ats/api/contracts/facets/IAsset.md index 41f6736709..4de00b34b4 100644 --- a/docs/ats/api/contracts/facets/IAsset.md +++ b/docs/ats/api/contracts/facets/IAsset.md @@ -2139,18 +2139,20 @@ Gets the ids of the clearings for a token holder by partition and clearing opera ### getConfigInfo ```solidity -function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_) +function getConfigInfo() external view returns (address resolver_, bytes8 proxyVersion_, bytes32 configurationId_, uint256 configurationVersion_, bool replacementEnabled_) ``` Returns the active resolver address, configuration identifier, and version. #### Returns -| Name | Type | Description | -| ----------------- | ------- | ----------------------------------------------- | -| resolver\_ | address | Address of the current Business Logic Resolver. | -| configurationId\_ | bytes32 | Identifier of the active configuration. | -| version\_ | uint256 | Version number of the active configuration. | +| Name | Type | Description | +| ---------------------- | ------- | ----------------------------------------------- | +| resolver\_ | address | Address of the current Business Logic Resolver. | +| proxyVersion\_ | bytes8 | proxy version. | +| configurationId\_ | bytes32 | Identifier of the active configuration. | +| configurationVersion\_ | uint256 | Version number of the active configuration. | +| replacementEnabled\_ | bool | Whether replacement is enabled. | ### getControlListCount @@ -8733,21 +8735,36 @@ Updates the arbitrary data stored for an existing proceed recipient. | \_proceedRecipient | address | Address of the recipient whose data should be updated. | | \_data | bytes | New arbitrary data to store for the recipient. | +### updateReplacementEnabled + +```solidity +function updateReplacementEnabled(bool _newReplacementEnabled) external nonpayable +``` + +For the current BLR update its configuration + +#### Parameters + +| Name | Type | Description | +| ----------------------- | ---- | ------------------------------------- | +| \_newReplacementEnabled | bool | The replacement enabled flag to set\* | + ### updateResolver ```solidity -function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion) external nonpayable +function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion, bool _newReplacementEnabled) external nonpayable ``` Replaces the Business Logic Resolver with a new one, setting configuration and version. #### Parameters -| Name | Type | Description | -| -------------------- | ------------------------------- | ------------------------------------------------------------- | -| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | -| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | -| \_newVersion | uint256 | The version number associated with the new configuration. | +| Name | Type | Description | +| ----------------------- | ------------------------------- | ------------------------------------------------------------- | +| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | +| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | +| \_newVersion | uint256 | The version number associated with the new configuration. | +| \_newReplacementEnabled | bool | The replacement enabled flag to set. | ### version diff --git a/docs/ats/api/contracts/facets/accessControl/AccessControl.md b/docs/ats/api/contracts/facets/accessControl/AccessControl.md index 9fe93a6bb9..08e7c37acc 100644 --- a/docs/ats/api/contracts/facets/accessControl/AccessControl.md +++ b/docs/ats/api/contracts/facets/accessControl/AccessControl.md @@ -425,6 +425,20 @@ Thrown when the `roles` and `actives` arrays passed to `applyRoles` differ in le | rolesLength | uint256 | Length of the roles array. | | activesLength | uint256 | Length of the actives array. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/accessControl/AccessControlFacet.md b/docs/ats/api/contracts/facets/accessControl/AccessControlFacet.md index e244445c72..eecc58aef9 100644 --- a/docs/ats/api/contracts/facets/accessControl/AccessControlFacet.md +++ b/docs/ats/api/contracts/facets/accessControl/AccessControlFacet.md @@ -482,6 +482,20 @@ Thrown when the `roles` and `actives` arrays passed to `applyRoles` differ in le | rolesLength | uint256 | Length of the roles array. | | activesLength | uint256 | Length of the actives array. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/accessControl/AccessControlOperational.md b/docs/ats/api/contracts/facets/accessControl/AccessControlOperational.md index 3cdfc3bc06..c6ac5b48ff 100644 --- a/docs/ats/api/contracts/facets/accessControl/AccessControlOperational.md +++ b/docs/ats/api/contracts/facets/accessControl/AccessControlOperational.md @@ -440,6 +440,20 @@ Thrown when the `roles` and `actives` arrays passed to `applyRoles` differ in le | rolesLength | uint256 | Length of the roles array. | | activesLength | uint256 | Length of the actives array. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/adjustBalances/AdjustBalances.md b/docs/ats/api/contracts/facets/adjustBalances/AdjustBalances.md index 31debf11ef..eefd502ba3 100644 --- a/docs/ats/api/contracts/facets/adjustBalances/AdjustBalances.md +++ b/docs/ats/api/contracts/facets/adjustBalances/AdjustBalances.md @@ -184,6 +184,20 @@ error TotalSupplyOverflow() Reverts when the proposed factor would overflow the projected total supply. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/adjustBalances/AdjustBalancesFacet.md b/docs/ats/api/contracts/facets/adjustBalances/AdjustBalancesFacet.md index 872b6a9b1a..57c20fea54 100644 --- a/docs/ats/api/contracts/facets/adjustBalances/AdjustBalancesFacet.md +++ b/docs/ats/api/contracts/facets/adjustBalances/AdjustBalancesFacet.md @@ -226,6 +226,20 @@ error TotalSupplyOverflow() Reverts when the proposed factor would overflow the projected total supply. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/allowance/Allowance.md b/docs/ats/api/contracts/facets/allowance/Allowance.md index 33ee8054d4..9023e0bae1 100644 --- a/docs/ats/api/contracts/facets/allowance/Allowance.md +++ b/docs/ats/api/contracts/facets/allowance/Allowance.md @@ -238,6 +238,20 @@ error SpenderWithZeroAddress() Reverts when the zero address is supplied as `spender` in an allowance update. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/allowance/AllowanceFacet.md b/docs/ats/api/contracts/facets/allowance/AllowanceFacet.md index bb776425ed..0a9e85de7f 100644 --- a/docs/ats/api/contracts/facets/allowance/AllowanceFacet.md +++ b/docs/ats/api/contracts/facets/allowance/AllowanceFacet.md @@ -278,6 +278,20 @@ error SpenderWithZeroAddress() Reverts when the zero address is supplied as `spender` in an allowance update. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/amortization/Amortization.md b/docs/ats/api/contracts/facets/amortization/Amortization.md index ff282e4b54..6744db1ddf 100644 --- a/docs/ats/api/contracts/facets/amortization/Amortization.md +++ b/docs/ats/api/contracts/facets/amortization/Amortization.md @@ -726,6 +726,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/amortization/AmortizationFacet.md b/docs/ats/api/contracts/facets/amortization/AmortizationFacet.md index d7c53640cb..6c4766b21b 100644 --- a/docs/ats/api/contracts/facets/amortization/AmortizationFacet.md +++ b/docs/ats/api/contracts/facets/amortization/AmortizationFacet.md @@ -768,6 +768,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTracker/BalanceTracker.md b/docs/ats/api/contracts/facets/balanceTracker/BalanceTracker.md index 8a9f368075..df95aa2442 100644 --- a/docs/ats/api/contracts/facets/balanceTracker/BalanceTracker.md +++ b/docs/ats/api/contracts/facets/balanceTracker/BalanceTracker.md @@ -124,6 +124,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTracker/BalanceTrackerFacet.md b/docs/ats/api/contracts/facets/balanceTracker/BalanceTrackerFacet.md index 97a08086b4..7f59c8cb9a 100644 --- a/docs/ats/api/contracts/facets/balanceTracker/BalanceTrackerFacet.md +++ b/docs/ats/api/contracts/facets/balanceTracker/BalanceTrackerFacet.md @@ -166,6 +166,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjusted.md b/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjusted.md index b460bd6899..14ed9e09f3 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjusted.md +++ b/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjusted.md @@ -85,6 +85,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjustedFacet.md b/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjustedFacet.md index c11f080bbf..2ce610e7cc 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjustedFacet.md +++ b/docs/ats/api/contracts/facets/balanceTrackerAdjusted/BalanceTrackerAdjustedFacet.md @@ -127,6 +127,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshot.md b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshot.md index 63e413eed2..fc472885b0 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshot.md +++ b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshot.md @@ -149,6 +149,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshotFacet.md b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshotFacet.md index f486e7ac77..9f7ff6396e 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshot/BalanceTrackerAtSnapshotFacet.md @@ -191,6 +191,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartition.md b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartition.md index 6c5b24073d..1e666f0a76 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartition.md +++ b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartition.md @@ -129,6 +129,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartitionFacet.md b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartitionFacet.md index fedd33644f..bf50d2e9e1 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/balanceTrackerAtSnapshotByPartition/BalanceTrackerAtSnapshotByPartitionFacet.md @@ -171,6 +171,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartition.md b/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartition.md index 8e0525be5c..2f3e494410 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartition.md +++ b/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartition.md @@ -126,6 +126,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartitionFacet.md b/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartitionFacet.md index 90f1f7966f..472653c423 100644 --- a/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/balanceTrackerByPartition/BalanceTrackerByPartitionFacet.md @@ -168,6 +168,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchBurn/BatchBurn.md b/docs/ats/api/contracts/facets/batchBurn/BatchBurn.md index e3ebb76eeb..0ba228fb03 100644 --- a/docs/ats/api/contracts/facets/batchBurn/BatchBurn.md +++ b/docs/ats/api/contracts/facets/batchBurn/BatchBurn.md @@ -169,6 +169,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchBurn/BatchBurnFacet.md b/docs/ats/api/contracts/facets/batchBurn/BatchBurnFacet.md index 6adf433bd4..efeec020f1 100644 --- a/docs/ats/api/contracts/facets/batchBurn/BatchBurnFacet.md +++ b/docs/ats/api/contracts/facets/batchBurn/BatchBurnFacet.md @@ -211,6 +211,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchController/BatchController.md b/docs/ats/api/contracts/facets/batchController/BatchController.md index 3173d5776f..38dd79226b 100644 --- a/docs/ats/api/contracts/facets/batchController/BatchController.md +++ b/docs/ats/api/contracts/facets/batchController/BatchController.md @@ -171,6 +171,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchController/BatchControllerFacet.md b/docs/ats/api/contracts/facets/batchController/BatchControllerFacet.md index 231fc2ff54..892490584b 100644 --- a/docs/ats/api/contracts/facets/batchController/BatchControllerFacet.md +++ b/docs/ats/api/contracts/facets/batchController/BatchControllerFacet.md @@ -213,6 +213,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchFreeze/BatchFreeze.md b/docs/ats/api/contracts/facets/batchFreeze/BatchFreeze.md index 2c8dacff58..8daaad8c68 100644 --- a/docs/ats/api/contracts/facets/batchFreeze/BatchFreeze.md +++ b/docs/ats/api/contracts/facets/batchFreeze/BatchFreeze.md @@ -396,6 +396,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchFreeze/BatchFreezeFacet.md b/docs/ats/api/contracts/facets/batchFreeze/BatchFreezeFacet.md index 7963b5299b..3e607da019 100644 --- a/docs/ats/api/contracts/facets/batchFreeze/BatchFreezeFacet.md +++ b/docs/ats/api/contracts/facets/batchFreeze/BatchFreezeFacet.md @@ -438,6 +438,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchMint/BatchMint.md b/docs/ats/api/contracts/facets/batchMint/BatchMint.md index b4e35c088e..037eb88ff7 100644 --- a/docs/ats/api/contracts/facets/batchMint/BatchMint.md +++ b/docs/ats/api/contracts/facets/batchMint/BatchMint.md @@ -174,6 +174,20 @@ error NotAllowedInMultiPartitionMode() Thrown when a single-partition operation is attempted on a multi-partition token. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchMint/BatchMintFacet.md b/docs/ats/api/contracts/facets/batchMint/BatchMintFacet.md index bb8b619ec4..81c9d0f9e2 100644 --- a/docs/ats/api/contracts/facets/batchMint/BatchMintFacet.md +++ b/docs/ats/api/contracts/facets/batchMint/BatchMintFacet.md @@ -216,6 +216,20 @@ error NotAllowedInMultiPartitionMode() Thrown when a single-partition operation is attempted on a multi-partition token. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchTransfer/BatchTransfer.md b/docs/ats/api/contracts/facets/batchTransfer/BatchTransfer.md index 04b8e95c88..5336de1da9 100644 --- a/docs/ats/api/contracts/facets/batchTransfer/BatchTransfer.md +++ b/docs/ats/api/contracts/facets/batchTransfer/BatchTransfer.md @@ -143,6 +143,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/batchTransfer/BatchTransferFacet.md b/docs/ats/api/contracts/facets/batchTransfer/BatchTransferFacet.md index fb6a6b99b1..0e8cb28bda 100644 --- a/docs/ats/api/contracts/facets/batchTransfer/BatchTransferFacet.md +++ b/docs/ats/api/contracts/facets/batchTransfer/BatchTransferFacet.md @@ -185,6 +185,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/burn/Burn.md b/docs/ats/api/contracts/facets/burn/Burn.md index 8635928ea1..5d57485c59 100644 --- a/docs/ats/api/contracts/facets/burn/Burn.md +++ b/docs/ats/api/contracts/facets/burn/Burn.md @@ -224,6 +224,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/burn/BurnFacet.md b/docs/ats/api/contracts/facets/burn/BurnFacet.md index 825ec32e70..b7461e247a 100644 --- a/docs/ats/api/contracts/facets/burn/BurnFacet.md +++ b/docs/ats/api/contracts/facets/burn/BurnFacet.md @@ -268,6 +268,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/burnByPartition/BurnByPartition.md b/docs/ats/api/contracts/facets/burnByPartition/BurnByPartition.md index e135587581..59c7e2cf10 100644 --- a/docs/ats/api/contracts/facets/burnByPartition/BurnByPartition.md +++ b/docs/ats/api/contracts/facets/burnByPartition/BurnByPartition.md @@ -134,6 +134,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/burnByPartition/BurnByPartitionFacet.md b/docs/ats/api/contracts/facets/burnByPartition/BurnByPartitionFacet.md index 94531d8dba..6c29e3e205 100644 --- a/docs/ats/api/contracts/facets/burnByPartition/BurnByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/burnByPartition/BurnByPartitionFacet.md @@ -176,6 +176,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/cap/Cap.md b/docs/ats/api/contracts/facets/cap/Cap.md index 9480490013..5db47ced87 100644 --- a/docs/ats/api/contracts/facets/cap/Cap.md +++ b/docs/ats/api/contracts/facets/cap/Cap.md @@ -244,6 +244,20 @@ Thrown when a proposed new global cap is below the current adjusted total supply | maxSupply | uint256 | The proposed new maximum supply. | | totalSupply | uint256 | The current adjusted total supply that exceeds it. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/cap/CapFacet.md b/docs/ats/api/contracts/facets/cap/CapFacet.md index f5123a669e..59c906a9f6 100644 --- a/docs/ats/api/contracts/facets/cap/CapFacet.md +++ b/docs/ats/api/contracts/facets/cap/CapFacet.md @@ -286,6 +286,20 @@ Thrown when a proposed new global cap is below the current adjusted total supply | maxSupply | uint256 | The proposed new maximum supply. | | totalSupply | uint256 | The current adjusted total supply that exceeds it. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/capByPartition/CapByPartition.md b/docs/ats/api/contracts/facets/capByPartition/CapByPartition.md index 55a4d5105f..6b8363cab7 100644 --- a/docs/ats/api/contracts/facets/capByPartition/CapByPartition.md +++ b/docs/ats/api/contracts/facets/capByPartition/CapByPartition.md @@ -181,6 +181,20 @@ Thrown when a proposed new partition cap is below the partition's current ad | maxSupply | uint256 | The proposed new maximum supply for the partition. | | totalSupply | uint256 | The current adjusted total supply for the partition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/capByPartition/CapByPartitionFacet.md b/docs/ats/api/contracts/facets/capByPartition/CapByPartitionFacet.md index f40df9d0ac..962f653408 100644 --- a/docs/ats/api/contracts/facets/capByPartition/CapByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/capByPartition/CapByPartitionFacet.md @@ -223,6 +223,20 @@ Thrown when a proposed new partition cap is below the partition's current ad | maxSupply | uint256 | The proposed new maximum supply for the partition. | | totalSupply | uint256 | The current adjusted total supply for the partition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearing/Clearing.md b/docs/ats/api/contracts/facets/clearing/Clearing.md index 4a672f4716..87ab6a90e7 100644 --- a/docs/ats/api/contracts/facets/clearing/Clearing.md +++ b/docs/ats/api/contracts/facets/clearing/Clearing.md @@ -486,6 +486,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearing/ClearingFacet.md b/docs/ats/api/contracts/facets/clearing/ClearingFacet.md index 26e410a920..e5b1c1d2b3 100644 --- a/docs/ats/api/contracts/facets/clearing/ClearingFacet.md +++ b/docs/ats/api/contracts/facets/clearing/ClearingFacet.md @@ -528,6 +528,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshot.md b/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshot.md index ca5e051932..29bcc93fc7 100644 --- a/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshot.md +++ b/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshot.md @@ -107,6 +107,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshotFacet.md b/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshotFacet.md index 03b03917a4..be3ede2595 100644 --- a/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/clearingAtSnapshot/ClearingAtSnapshotFacet.md @@ -149,6 +149,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartition.md b/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartition.md index 77233f2ac0..51d8e08c83 100644 --- a/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartition.md +++ b/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartition.md @@ -108,6 +108,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartitionFacet.md b/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartitionFacet.md index 48077bdf80..7d5aa6ed57 100644 --- a/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/clearingAtSnapshotByPartition/ClearingAtSnapshotByPartitionFacet.md @@ -150,6 +150,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartition.md b/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartition.md index 2012f37f59..cd0d626165 100644 --- a/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartition.md +++ b/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartition.md @@ -666,6 +666,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartitionFacet.md b/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartitionFacet.md index f3f0461424..54ccc3b73d 100644 --- a/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/clearingByPartition/ClearingByPartitionFacet.md @@ -708,6 +708,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartition.md b/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartition.md index 276f40756e..8a6aa87f81 100644 --- a/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartition.md +++ b/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartition.md @@ -480,6 +480,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartitionFacet.md b/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartitionFacet.md index 5efac0cae0..baa948809a 100644 --- a/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/clearingHoldByPartition/ClearingHoldByPartitionFacet.md @@ -522,6 +522,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/compliance/Compliance.md b/docs/ats/api/contracts/facets/compliance/Compliance.md index a12e2abd9c..2e11517af0 100644 --- a/docs/ats/api/contracts/facets/compliance/Compliance.md +++ b/docs/ats/api/contracts/facets/compliance/Compliance.md @@ -212,6 +212,20 @@ error NotAllowedInMultiPartitionMode() Thrown when a single-partition operation is attempted on a multi-partition token. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/compliance/ComplianceFacet.md b/docs/ats/api/contracts/facets/compliance/ComplianceFacet.md index 38b3d58055..14922457db 100644 --- a/docs/ats/api/contracts/facets/compliance/ComplianceFacet.md +++ b/docs/ats/api/contracts/facets/compliance/ComplianceFacet.md @@ -254,6 +254,20 @@ error NotAllowedInMultiPartitionMode() Thrown when a single-partition operation is attempted on a multi-partition token. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartition.md b/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartition.md index 19c2c61786..9c33926f4a 100644 --- a/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartition.md +++ b/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartition.md @@ -121,6 +121,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartitionFacet.md b/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartitionFacet.md index df8b3e80ee..cfc3c84e8c 100644 --- a/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/complianceByPartition/ComplianceByPartitionFacet.md @@ -163,6 +163,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controlList/ControlList.md b/docs/ats/api/contracts/facets/controlList/ControlList.md index 4b4bd70c25..b2902b4c6b 100644 --- a/docs/ats/api/contracts/facets/controlList/ControlList.md +++ b/docs/ats/api/contracts/facets/controlList/ControlList.md @@ -282,6 +282,20 @@ Thrown when attempting to remove an address that is not present in the control l | ------- | ------- | ------------------------------- | | account | address | The address that was not found. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controlList/ControlListFacet.md b/docs/ats/api/contracts/facets/controlList/ControlListFacet.md index 3f648361d2..87ada67251 100644 --- a/docs/ats/api/contracts/facets/controlList/ControlListFacet.md +++ b/docs/ats/api/contracts/facets/controlList/ControlListFacet.md @@ -324,6 +324,20 @@ Thrown when attempting to remove an address that is not present in the control l | ------- | ------- | ------------------------------- | | account | address | The address that was not found. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controller/Controller.md b/docs/ats/api/contracts/facets/controller/Controller.md index 116ff1cd4e..7f021969d5 100644 --- a/docs/ats/api/contracts/facets/controller/Controller.md +++ b/docs/ats/api/contracts/facets/controller/Controller.md @@ -521,6 +521,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controller/ControllerFacet.md b/docs/ats/api/contracts/facets/controller/ControllerFacet.md index a9d94a317f..4e6365fd22 100644 --- a/docs/ats/api/contracts/facets/controller/ControllerFacet.md +++ b/docs/ats/api/contracts/facets/controller/ControllerFacet.md @@ -565,6 +565,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartition.md b/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartition.md index fc106a4394..f0923e4b95 100644 --- a/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartition.md +++ b/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartition.md @@ -351,6 +351,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartitionFacet.md b/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartitionFacet.md index b4a29d4e73..cd461ab298 100644 --- a/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/controllerByPartition/ControllerByPartitionFacet.md @@ -393,6 +393,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartition.md b/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartition.md index fa0fb526d4..113fcfb91b 100644 --- a/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartition.md +++ b/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartition.md @@ -357,6 +357,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartitionFacet.md b/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartitionFacet.md index cdb151ceef..98de80a07a 100644 --- a/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/controllerHoldByPartition/ControllerHoldByPartitionFacet.md @@ -399,6 +399,20 @@ error TokenIsNotControllable() Thrown when an operation requires the token to be controllable but it is not. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/core/Core.md b/docs/ats/api/contracts/facets/core/Core.md index 94a669301b..09316ea2af 100644 --- a/docs/ats/api/contracts/facets/core/Core.md +++ b/docs/ats/api/contracts/facets/core/Core.md @@ -217,6 +217,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/core/CoreFacet.md b/docs/ats/api/contracts/facets/core/CoreFacet.md index 9090784479..77d3860cbc 100644 --- a/docs/ats/api/contracts/facets/core/CoreFacet.md +++ b/docs/ats/api/contracts/facets/core/CoreFacet.md @@ -259,6 +259,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjusted.md b/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjusted.md index d7a5765d38..9c55fbf845 100644 --- a/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjusted.md +++ b/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjusted.md @@ -86,6 +86,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjustedFacet.md b/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjustedFacet.md index a7eff15d2f..d8ac4ec506 100644 --- a/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjustedFacet.md +++ b/docs/ats/api/contracts/facets/coreAdjusted/CoreAdjustedFacet.md @@ -128,6 +128,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshot.md b/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshot.md index cefe82197a..85ee0ad4dd 100644 --- a/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshot.md +++ b/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshot.md @@ -106,6 +106,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshotFacet.md b/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshotFacet.md index d6e7749c44..58ebb136bc 100644 --- a/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/coreAtSnapshot/CoreAtSnapshotFacet.md @@ -148,6 +148,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/corporateActions/CorporateActions.md b/docs/ats/api/contracts/facets/corporateActions/CorporateActions.md index 0910ee319d..86549b519a 100644 --- a/docs/ats/api/contracts/facets/corporateActions/CorporateActions.md +++ b/docs/ats/api/contracts/facets/corporateActions/CorporateActions.md @@ -481,6 +481,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/corporateActions/CorporateActionsFacet.md b/docs/ats/api/contracts/facets/corporateActions/CorporateActionsFacet.md index f0f8c4edb3..cfb3f8c8b6 100644 --- a/docs/ats/api/contracts/facets/corporateActions/CorporateActionsFacet.md +++ b/docs/ats/api/contracts/facets/corporateActions/CorporateActionsFacet.md @@ -523,6 +523,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/coupon/Coupon.md b/docs/ats/api/contracts/facets/coupon/Coupon.md index d58ba0fd64..907aa9c584 100644 --- a/docs/ats/api/contracts/facets/coupon/Coupon.md +++ b/docs/ats/api/contracts/facets/coupon/Coupon.md @@ -448,6 +448,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/coupon/CouponFacet.md b/docs/ats/api/contracts/facets/coupon/CouponFacet.md index 6bceb2f085..06c51ab947 100644 --- a/docs/ats/api/contracts/facets/coupon/CouponFacet.md +++ b/docs/ats/api/contracts/facets/coupon/CouponFacet.md @@ -492,6 +492,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/couponListing/CouponListing.md b/docs/ats/api/contracts/facets/couponListing/CouponListing.md index adbb5c9db7..e7179acadf 100644 --- a/docs/ats/api/contracts/facets/couponListing/CouponListing.md +++ b/docs/ats/api/contracts/facets/couponListing/CouponListing.md @@ -169,6 +169,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/couponListing/CouponListingFacet.md b/docs/ats/api/contracts/facets/couponListing/CouponListingFacet.md index 6ca72e1f1f..145563fc36 100644 --- a/docs/ats/api/contracts/facets/couponListing/CouponListingFacet.md +++ b/docs/ats/api/contracts/facets/couponListing/CouponListingFacet.md @@ -211,6 +211,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHolders.md b/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHolders.md index 122406bc2a..f45aa26bb3 100644 --- a/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHolders.md +++ b/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHolders.md @@ -252,6 +252,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHoldersFacet.md b/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHoldersFacet.md index c8d9b49000..e145ce5df2 100644 --- a/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHoldersFacet.md +++ b/docs/ats/api/contracts/facets/couponSecurityHolders/CouponSecurityHoldersFacet.md @@ -294,6 +294,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/customData/CustomData.md b/docs/ats/api/contracts/facets/customData/CustomData.md index ab47488e8e..f86cc983bc 100644 --- a/docs/ats/api/contracts/facets/customData/CustomData.md +++ b/docs/ats/api/contracts/facets/customData/CustomData.md @@ -134,6 +134,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/customData/CustomDataFacet.md b/docs/ats/api/contracts/facets/customData/CustomDataFacet.md index 75dec78ca8..1acca0b550 100644 --- a/docs/ats/api/contracts/facets/customData/CustomDataFacet.md +++ b/docs/ats/api/contracts/facets/customData/CustomDataFacet.md @@ -176,6 +176,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/deactivate/Deactivate.md b/docs/ats/api/contracts/facets/deactivate/Deactivate.md index 55de012c81..7dff78bdc1 100644 --- a/docs/ats/api/contracts/facets/deactivate/Deactivate.md +++ b/docs/ats/api/contracts/facets/deactivate/Deactivate.md @@ -119,6 +119,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/deactivate/DeactivateFacet.md b/docs/ats/api/contracts/facets/deactivate/DeactivateFacet.md index ec79ae3b09..c49b21f857 100644 --- a/docs/ats/api/contracts/facets/deactivate/DeactivateFacet.md +++ b/docs/ats/api/contracts/facets/deactivate/DeactivateFacet.md @@ -161,6 +161,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/dividend/Dividend.md b/docs/ats/api/contracts/facets/dividend/Dividend.md index c3e17dadda..4c112d56f5 100644 --- a/docs/ats/api/contracts/facets/dividend/Dividend.md +++ b/docs/ats/api/contracts/facets/dividend/Dividend.md @@ -379,6 +379,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/dividend/DividendFacet.md b/docs/ats/api/contracts/facets/dividend/DividendFacet.md index 511a145ca5..094cd0a167 100644 --- a/docs/ats/api/contracts/facets/dividend/DividendFacet.md +++ b/docs/ats/api/contracts/facets/dividend/DividendFacet.md @@ -421,6 +421,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHolders.md b/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHolders.md index 8d73667b6a..c762bc5c5b 100644 --- a/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHolders.md +++ b/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHolders.md @@ -132,6 +132,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHoldersFacet.md b/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHoldersFacet.md index e2db6c39b3..56aaccc6e2 100644 --- a/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHoldersFacet.md +++ b/docs/ats/api/contracts/facets/dividendSecurityHolders/DividendSecurityHoldersFacet.md @@ -174,6 +174,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/documentation/Documentation.md b/docs/ats/api/contracts/facets/documentation/Documentation.md index 62416b2f95..3f1539b8a6 100644 --- a/docs/ats/api/contracts/facets/documentation/Documentation.md +++ b/docs/ats/api/contracts/facets/documentation/Documentation.md @@ -243,6 +243,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/documentation/DocumentationFacet.md b/docs/ats/api/contracts/facets/documentation/DocumentationFacet.md index 693d1be989..c4093187cb 100644 --- a/docs/ats/api/contracts/facets/documentation/DocumentationFacet.md +++ b/docs/ats/api/contracts/facets/documentation/DocumentationFacet.md @@ -285,6 +285,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/eip712/EIP712.md b/docs/ats/api/contracts/facets/eip712/EIP712.md index 97cf5ece48..1762488180 100644 --- a/docs/ats/api/contracts/facets/eip712/EIP712.md +++ b/docs/ats/api/contracts/facets/eip712/EIP712.md @@ -80,6 +80,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/eip712/EIP712Facet.md b/docs/ats/api/contracts/facets/eip712/EIP712Facet.md index 13bf5877d6..1ee67a5138 100644 --- a/docs/ats/api/contracts/facets/eip712/EIP712Facet.md +++ b/docs/ats/api/contracts/facets/eip712/EIP712Facet.md @@ -122,6 +122,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/erc20Permit/ERC20Permit.md b/docs/ats/api/contracts/facets/erc20Permit/ERC20Permit.md index f5ff33dd1c..7a6c788f5e 100644 --- a/docs/ats/api/contracts/facets/erc20Permit/ERC20Permit.md +++ b/docs/ats/api/contracts/facets/erc20Permit/ERC20Permit.md @@ -236,6 +236,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/erc20Permit/ERC20PermitFacet.md b/docs/ats/api/contracts/facets/erc20Permit/ERC20PermitFacet.md index eebc97f7a9..3173468fc6 100644 --- a/docs/ats/api/contracts/facets/erc20Permit/ERC20PermitFacet.md +++ b/docs/ats/api/contracts/facets/erc20Permit/ERC20PermitFacet.md @@ -276,6 +276,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/erc20Votes/ERC20Votes.md b/docs/ats/api/contracts/facets/erc20Votes/ERC20Votes.md index 821a1c84fd..fe3901d614 100644 --- a/docs/ats/api/contracts/facets/erc20Votes/ERC20Votes.md +++ b/docs/ats/api/contracts/facets/erc20Votes/ERC20Votes.md @@ -382,6 +382,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/erc20Votes/ERC20VotesFacet.md b/docs/ats/api/contracts/facets/erc20Votes/ERC20VotesFacet.md index d1963b35b1..0dd4d67605 100644 --- a/docs/ats/api/contracts/facets/erc20Votes/ERC20VotesFacet.md +++ b/docs/ats/api/contracts/facets/erc20Votes/ERC20VotesFacet.md @@ -424,6 +424,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagement.md b/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagement.md index 513858bee4..1dd4670cc4 100644 --- a/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagement.md +++ b/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagement.md @@ -353,6 +353,20 @@ Thrown when attempting to remove an address not present in the external control | ----------- | ------- | ---------------------------------------------------- | | controlList | address | The unlisted external control list contract address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagementFacet.md b/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagementFacet.md index d1ee47183a..8ec2a58c93 100644 --- a/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagementFacet.md +++ b/docs/ats/api/contracts/facets/externalControlListManagement/ExternalControlListManagementFacet.md @@ -395,6 +395,20 @@ Thrown when attempting to remove an address not present in the external control | ----------- | ------- | ---------------------------------------------------- | | controlList | address | The unlisted external control list contract address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagement.md b/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagement.md index 174cdd3973..0fa024667d 100644 --- a/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagement.md +++ b/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagement.md @@ -376,6 +376,20 @@ Thrown when attempting to remove an address not present in the external KYC list | ------- | ------- | ------------------------------------------------ | | kycList | address | The unlisted external KYC list contract address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagementFacet.md b/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagementFacet.md index 2487c33ecc..9411a20f6e 100644 --- a/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagementFacet.md +++ b/docs/ats/api/contracts/facets/externalKycListManagement/ExternalKycListManagementFacet.md @@ -418,6 +418,20 @@ Thrown when attempting to remove an address not present in the external KYC list | ------- | ------- | ------------------------------------------------ | | kycList | address | The unlisted external KYC list contract address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagement.md b/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagement.md index 56d4e9dd57..9a309b7702 100644 --- a/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagement.md +++ b/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagement.md @@ -353,6 +353,20 @@ Thrown when attempting to remove an address not present in the external pause li | ----- | ------- | --------------------------------------------- | | pause | address | The unlisted external pause contract address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagementFacet.md b/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagementFacet.md index 0433310796..96095cada6 100644 --- a/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagementFacet.md +++ b/docs/ats/api/contracts/facets/externalPauseManagement/ExternalPauseManagementFacet.md @@ -395,6 +395,20 @@ Thrown when attempting to remove an address not present in the external pause li | ----- | ------- | --------------------------------------------- | | pause | address | The unlisted external pause contract address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/fixedRate/FixedRate.md b/docs/ats/api/contracts/facets/fixedRate/FixedRate.md index 7c78d9c53d..2428b8c0ce 100644 --- a/docs/ats/api/contracts/facets/fixedRate/FixedRate.md +++ b/docs/ats/api/contracts/facets/fixedRate/FixedRate.md @@ -159,6 +159,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/fixedRate/FixedRateFacet.md b/docs/ats/api/contracts/facets/fixedRate/FixedRateFacet.md index 99f743e71f..45b8fe5501 100644 --- a/docs/ats/api/contracts/facets/fixedRate/FixedRateFacet.md +++ b/docs/ats/api/contracts/facets/fixedRate/FixedRateFacet.md @@ -201,6 +201,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/freeze/Freeze.md b/docs/ats/api/contracts/facets/freeze/Freeze.md index 3a4b0adf57..e79c33da80 100644 --- a/docs/ats/api/contracts/facets/freeze/Freeze.md +++ b/docs/ats/api/contracts/facets/freeze/Freeze.md @@ -422,6 +422,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/freeze/FreezeFacet.md b/docs/ats/api/contracts/facets/freeze/FreezeFacet.md index 48180d227d..bb0c82d974 100644 --- a/docs/ats/api/contracts/facets/freeze/FreezeFacet.md +++ b/docs/ats/api/contracts/facets/freeze/FreezeFacet.md @@ -464,6 +464,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshot.md b/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshot.md index 88e47b579b..d733d891eb 100644 --- a/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshot.md +++ b/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshot.md @@ -107,6 +107,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshotFacet.md b/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshotFacet.md index 3b1f847f25..8bd8f8599c 100644 --- a/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/freezeAtSnapshot/FreezeAtSnapshotFacet.md @@ -149,6 +149,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartition.md b/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartition.md index d54c936b71..ec90a1f19c 100644 --- a/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartition.md +++ b/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartition.md @@ -108,6 +108,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartitionFacet.md b/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartitionFacet.md index 3df569118b..e46a828b7f 100644 --- a/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/freezeAtSnapshotByPartition/FreezeAtSnapshotByPartitionFacet.md @@ -150,6 +150,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/hold/Hold.md b/docs/ats/api/contracts/facets/hold/Hold.md index 5abcd006a5..1313bf1231 100644 --- a/docs/ats/api/contracts/facets/hold/Hold.md +++ b/docs/ats/api/contracts/facets/hold/Hold.md @@ -314,6 +314,20 @@ error IsNotEscrow() Reverts when a caller that is not the recorded escrow attempts to execute the hold. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/hold/HoldFacet.md b/docs/ats/api/contracts/facets/hold/HoldFacet.md index e5f464e936..115ed00630 100644 --- a/docs/ats/api/contracts/facets/hold/HoldFacet.md +++ b/docs/ats/api/contracts/facets/hold/HoldFacet.md @@ -356,6 +356,20 @@ error IsNotEscrow() Reverts when a caller that is not the recorded escrow attempts to execute the hold. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshot.md b/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshot.md index 91e1bcf3e9..3100214092 100644 --- a/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshot.md +++ b/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshot.md @@ -109,6 +109,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshotFacet.md b/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshotFacet.md index a813e0c8a8..f8e0b83717 100644 --- a/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/holdAtSnapshot/HoldAtSnapshotFacet.md @@ -151,6 +151,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartition.md b/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartition.md index 048744f0de..71ba0a144b 100644 --- a/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartition.md +++ b/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartition.md @@ -108,6 +108,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartitionFacet.md b/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartitionFacet.md index 2edc6b4da8..bb3a5f02ab 100644 --- a/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/holdAtSnapshotByPartition/HoldAtSnapshotByPartitionFacet.md @@ -150,6 +150,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/holdByPartition/HoldByPartition.md b/docs/ats/api/contracts/facets/holdByPartition/HoldByPartition.md index 7f34348236..048e26319a 100644 --- a/docs/ats/api/contracts/facets/holdByPartition/HoldByPartition.md +++ b/docs/ats/api/contracts/facets/holdByPartition/HoldByPartition.md @@ -531,6 +531,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/holdByPartition/HoldByPartitionFacet.md b/docs/ats/api/contracts/facets/holdByPartition/HoldByPartitionFacet.md index 521e929e6e..eb06368509 100644 --- a/docs/ats/api/contracts/facets/holdByPartition/HoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/holdByPartition/HoldByPartitionFacet.md @@ -573,6 +573,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/identity/Identity.md b/docs/ats/api/contracts/facets/identity/Identity.md index df780ebfe7..da03cec413 100644 --- a/docs/ats/api/contracts/facets/identity/Identity.md +++ b/docs/ats/api/contracts/facets/identity/Identity.md @@ -199,6 +199,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/identity/IdentityFacet.md b/docs/ats/api/contracts/facets/identity/IdentityFacet.md index f7a8b49930..5e99e76894 100644 --- a/docs/ats/api/contracts/facets/identity/IdentityFacet.md +++ b/docs/ats/api/contracts/facets/identity/IdentityFacet.md @@ -241,6 +241,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/initializer/Initializer.md b/docs/ats/api/contracts/facets/initializer/Initializer.md index 254a96285c..85447eb7fe 100644 --- a/docs/ats/api/contracts/facets/initializer/Initializer.md +++ b/docs/ats/api/contracts/facets/initializer/Initializer.md @@ -279,6 +279,20 @@ Raised by `checkFacetNotReady` when a facet is already marked ready for the reso | facetId | bytes32 | Identifier of the facet already flagged as ready. | | versionId | uint256 | Version for which the facet is already ready. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/initializer/InitializerFacet.md b/docs/ats/api/contracts/facets/initializer/InitializerFacet.md index f1939d9f8d..3fe46378dc 100644 --- a/docs/ats/api/contracts/facets/initializer/InitializerFacet.md +++ b/docs/ats/api/contracts/facets/initializer/InitializerFacet.md @@ -321,6 +321,20 @@ Raised by `checkFacetNotReady` when a facet is already marked ready for the reso | facetId | bytes32 | Identifier of the facet already flagged as ready. | | versionId | uint256 | Version for which the facet is already ready. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/interestRate/InterestRate.md b/docs/ats/api/contracts/facets/interestRate/InterestRate.md index ebc05c4dd0..65069ae6b7 100644 --- a/docs/ats/api/contracts/facets/interestRate/InterestRate.md +++ b/docs/ats/api/contracts/facets/interestRate/InterestRate.md @@ -144,6 +144,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/interestRate/InterestRateFacet.md b/docs/ats/api/contracts/facets/interestRate/InterestRateFacet.md index bdab90fac9..5e61b20854 100644 --- a/docs/ats/api/contracts/facets/interestRate/InterestRateFacet.md +++ b/docs/ats/api/contracts/facets/interestRate/InterestRateFacet.md @@ -186,6 +186,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRate.md b/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRate.md index a296b9b636..abcb84c809 100644 --- a/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRate.md +++ b/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRate.md @@ -187,6 +187,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRateFacet.md b/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRateFacet.md index 44b07346fd..84a936f516 100644 --- a/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRateFacet.md +++ b/docs/ats/api/contracts/facets/kpiLinkedRate/KpiLinkedRateFacet.md @@ -229,6 +229,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/kpis/Kpis.md b/docs/ats/api/contracts/facets/kpis/Kpis.md index 9123eaf744..30ed3c52e7 100644 --- a/docs/ats/api/contracts/facets/kpis/Kpis.md +++ b/docs/ats/api/contracts/facets/kpis/Kpis.md @@ -264,6 +264,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/kpis/KpisFacet.md b/docs/ats/api/contracts/facets/kpis/KpisFacet.md index 04eb8dcd18..6afb81f459 100644 --- a/docs/ats/api/contracts/facets/kpis/KpisFacet.md +++ b/docs/ats/api/contracts/facets/kpis/KpisFacet.md @@ -306,6 +306,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/kyc/Kyc.md b/docs/ats/api/contracts/facets/kyc/Kyc.md index 98bf13c78e..0e615cbc96 100644 --- a/docs/ats/api/contracts/facets/kyc/Kyc.md +++ b/docs/ats/api/contracts/facets/kyc/Kyc.md @@ -361,6 +361,20 @@ Thrown when an operation that requires the token to be unpaused is attempted whi error KycIsNotGranted() ``` +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/kyc/KycFacet.md b/docs/ats/api/contracts/facets/kyc/KycFacet.md index dc3c69e671..9e7c518ae8 100644 --- a/docs/ats/api/contracts/facets/kyc/KycFacet.md +++ b/docs/ats/api/contracts/facets/kyc/KycFacet.md @@ -401,6 +401,20 @@ Thrown when an operation that requires the token to be unpaused is attempted whi error KycIsNotGranted() ``` +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/loan/Loan.md b/docs/ats/api/contracts/facets/loan/Loan.md index 19c6c10591..ea45f36472 100644 --- a/docs/ats/api/contracts/facets/loan/Loan.md +++ b/docs/ats/api/contracts/facets/loan/Loan.md @@ -153,6 +153,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/loan/LoanFacet.md b/docs/ats/api/contracts/facets/loan/LoanFacet.md index 2d963512e1..c55750b2a4 100644 --- a/docs/ats/api/contracts/facets/loan/LoanFacet.md +++ b/docs/ats/api/contracts/facets/loan/LoanFacet.md @@ -195,6 +195,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolio.md b/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolio.md index 71b9f0dc5e..861e20bd9e 100644 --- a/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolio.md +++ b/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolio.md @@ -523,6 +523,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolioFacet.md b/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolioFacet.md index e6d8e449bc..2d988725fa 100644 --- a/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolioFacet.md +++ b/docs/ats/api/contracts/facets/loansPortfolio/LoansPortfolioFacet.md @@ -565,6 +565,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lock/Lock.md b/docs/ats/api/contracts/facets/lock/Lock.md index fa36487750..b42a07a10e 100644 --- a/docs/ats/api/contracts/facets/lock/Lock.md +++ b/docs/ats/api/contracts/facets/lock/Lock.md @@ -557,6 +557,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lock/LockFacet.md b/docs/ats/api/contracts/facets/lock/LockFacet.md index c09fe2a819..8771551b74 100644 --- a/docs/ats/api/contracts/facets/lock/LockFacet.md +++ b/docs/ats/api/contracts/facets/lock/LockFacet.md @@ -599,6 +599,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshot.md b/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshot.md index d4de83dc1b..fb40cf049e 100644 --- a/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshot.md +++ b/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshot.md @@ -109,6 +109,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshotFacet.md b/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshotFacet.md index b720539a1e..071c337185 100644 --- a/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/lockAtSnapshot/LockAtSnapshotFacet.md @@ -151,6 +151,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartition.md b/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartition.md index 2171e82fc2..3342c79dec 100644 --- a/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartition.md +++ b/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartition.md @@ -108,6 +108,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartitionFacet.md b/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartitionFacet.md index 99532631aa..cc32ee4099 100644 --- a/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/lockAtSnapshotByPartition/LockAtSnapshotByPartitionFacet.md @@ -150,6 +150,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lockByPartition/LockByPartition.md b/docs/ats/api/contracts/facets/lockByPartition/LockByPartition.md index a90c01e9b6..19dd0e819f 100644 --- a/docs/ats/api/contracts/facets/lockByPartition/LockByPartition.md +++ b/docs/ats/api/contracts/facets/lockByPartition/LockByPartition.md @@ -494,6 +494,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/lockByPartition/LockByPartitionFacet.md b/docs/ats/api/contracts/facets/lockByPartition/LockByPartitionFacet.md index b4eb7ccf3f..6cb1c926a6 100644 --- a/docs/ats/api/contracts/facets/lockByPartition/LockByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/lockByPartition/LockByPartitionFacet.md @@ -536,6 +536,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/maturity/Maturity.md b/docs/ats/api/contracts/facets/maturity/Maturity.md index a2bc17ea45..2e16f41a45 100644 --- a/docs/ats/api/contracts/facets/maturity/Maturity.md +++ b/docs/ats/api/contracts/facets/maturity/Maturity.md @@ -211,6 +211,20 @@ Thrown when an operation that requires the token to be unpaused is attempted whi error MaturityDateInvalid() ``` +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/maturity/MaturityFacet.md b/docs/ats/api/contracts/facets/maturity/MaturityFacet.md index 36697d63f2..1b049f2817 100644 --- a/docs/ats/api/contracts/facets/maturity/MaturityFacet.md +++ b/docs/ats/api/contracts/facets/maturity/MaturityFacet.md @@ -253,6 +253,20 @@ Thrown when an operation that requires the token to be unpaused is attempted whi error MaturityDateInvalid() ``` +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartition.md b/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartition.md index e90981eb7b..1a37a9f598 100644 --- a/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartition.md +++ b/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartition.md @@ -161,6 +161,20 @@ Thrown when a multi-partition operation specifies a partition not permitted in s | --------- | ------- | ------------------------------------------------ | | partition | bytes32 | The disallowed partition supplied by the caller. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartitionFacet.md b/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartitionFacet.md index b678158c03..c06ac365c2 100644 --- a/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/maturityByPartition/MaturityByPartitionFacet.md @@ -205,6 +205,20 @@ Thrown when a multi-partition operation specifies a partition not permitted in s | --------- | ------- | ------------------------------------------------ | | partition | bytes32 | The disallowed partition supplied by the caller. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/mint/Mint.md b/docs/ats/api/contracts/facets/mint/Mint.md index 2b2fb6815f..9316e42f25 100644 --- a/docs/ats/api/contracts/facets/mint/Mint.md +++ b/docs/ats/api/contracts/facets/mint/Mint.md @@ -200,6 +200,20 @@ error NotAllowedInMultiPartitionMode() Thrown when a single-partition operation is attempted on a multi-partition token. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/mint/MintFacet.md b/docs/ats/api/contracts/facets/mint/MintFacet.md index c5a832dbbc..ef8ff085cf 100644 --- a/docs/ats/api/contracts/facets/mint/MintFacet.md +++ b/docs/ats/api/contracts/facets/mint/MintFacet.md @@ -242,6 +242,20 @@ error NotAllowedInMultiPartitionMode() Thrown when a single-partition operation is attempted on a multi-partition token. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/mintByPartition/MintByPartition.md b/docs/ats/api/contracts/facets/mintByPartition/MintByPartition.md index c5dc1dfcf8..69b8b07c13 100644 --- a/docs/ats/api/contracts/facets/mintByPartition/MintByPartition.md +++ b/docs/ats/api/contracts/facets/mintByPartition/MintByPartition.md @@ -165,6 +165,20 @@ Thrown when a multi-partition operation specifies a partition not permitted in s | --------- | ------- | ------------------------------------------------ | | partition | bytes32 | The disallowed partition supplied by the caller. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/mintByPartition/MintByPartitionFacet.md b/docs/ats/api/contracts/facets/mintByPartition/MintByPartitionFacet.md index 14f3bd2987..163e8b66f6 100644 --- a/docs/ats/api/contracts/facets/mintByPartition/MintByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/mintByPartition/MintByPartitionFacet.md @@ -207,6 +207,20 @@ Thrown when a multi-partition operation specifies a partition not permitted in s | --------- | ------- | ------------------------------------------------ | | partition | bytes32 | The disallowed partition supplied by the caller. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/nominalValue/NominalValue.md b/docs/ats/api/contracts/facets/nominalValue/NominalValue.md index 78298e3b52..5a61d8e92f 100644 --- a/docs/ats/api/contracts/facets/nominalValue/NominalValue.md +++ b/docs/ats/api/contracts/facets/nominalValue/NominalValue.md @@ -213,6 +213,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/nominalValue/NominalValueFacet.md b/docs/ats/api/contracts/facets/nominalValue/NominalValueFacet.md index 6c277e1c56..353c82e459 100644 --- a/docs/ats/api/contracts/facets/nominalValue/NominalValueFacet.md +++ b/docs/ats/api/contracts/facets/nominalValue/NominalValueFacet.md @@ -255,6 +255,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshot.md b/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshot.md index 10c16cfd69..7d33046f60 100644 --- a/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshot.md +++ b/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshot.md @@ -130,6 +130,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshotFacet.md b/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshotFacet.md index dfe5caee83..df3f57e6ff 100644 --- a/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/nominalValueAtSnapshot/NominalValueAtSnapshotFacet.md @@ -170,6 +170,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/nonces/Nonces.md b/docs/ats/api/contracts/facets/nonces/Nonces.md index fbfc61a536..dcb3cf2c3d 100644 --- a/docs/ats/api/contracts/facets/nonces/Nonces.md +++ b/docs/ats/api/contracts/facets/nonces/Nonces.md @@ -84,6 +84,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/nonces/NoncesFacet.md b/docs/ats/api/contracts/facets/nonces/NoncesFacet.md index d85fb0c624..207a8872ae 100644 --- a/docs/ats/api/contracts/facets/nonces/NoncesFacet.md +++ b/docs/ats/api/contracts/facets/nonces/NoncesFacet.md @@ -126,6 +126,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operator/Operator.md b/docs/ats/api/contracts/facets/operator/Operator.md index 9113aa810f..c4fe22be50 100644 --- a/docs/ats/api/contracts/facets/operator/Operator.md +++ b/docs/ats/api/contracts/facets/operator/Operator.md @@ -174,6 +174,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operator/OperatorFacet.md b/docs/ats/api/contracts/facets/operator/OperatorFacet.md index fd31cc60dc..ae2cf611f5 100644 --- a/docs/ats/api/contracts/facets/operator/OperatorFacet.md +++ b/docs/ats/api/contracts/facets/operator/OperatorFacet.md @@ -216,6 +216,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartition.md b/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartition.md index ae25614b19..fe4c8c656e 100644 --- a/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartition.md +++ b/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartition.md @@ -392,6 +392,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartitionFacet.md b/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartitionFacet.md index 5fe15352e9..811cb87302 100644 --- a/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/operatorByPartition/OperatorByPartitionFacet.md @@ -434,6 +434,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartition.md b/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartition.md index 969b1d2c60..4991a6f20b 100644 --- a/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartition.md +++ b/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartition.md @@ -475,6 +475,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartitionFacet.md b/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartitionFacet.md index a09f26157f..4dea72605c 100644 --- a/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/operatorClearingByPartition/OperatorClearingByPartitionFacet.md @@ -517,6 +517,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartition.md b/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartition.md index 7dc8a1b395..d18a2440d9 100644 --- a/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartition.md +++ b/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartition.md @@ -475,6 +475,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartitionFacet.md b/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartitionFacet.md index 063da7a1af..d54f0fe9d3 100644 --- a/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/operatorClearingHoldByPartition/OperatorClearingHoldByPartitionFacet.md @@ -517,6 +517,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartition.md b/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartition.md index 05f6f61e04..aca8415ffb 100644 --- a/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartition.md +++ b/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartition.md @@ -380,6 +380,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartitionFacet.md b/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartitionFacet.md index 46c7a8a7e0..d2c887dbad 100644 --- a/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/operatorHoldByPartition/OperatorHoldByPartitionFacet.md @@ -422,6 +422,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/partitions/Partitions.md b/docs/ats/api/contracts/facets/partitions/Partitions.md index acec15e57e..536ad65498 100644 --- a/docs/ats/api/contracts/facets/partitions/Partitions.md +++ b/docs/ats/api/contracts/facets/partitions/Partitions.md @@ -110,6 +110,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/partitions/PartitionsFacet.md b/docs/ats/api/contracts/facets/partitions/PartitionsFacet.md index b426722d91..f2e5592e42 100644 --- a/docs/ats/api/contracts/facets/partitions/PartitionsFacet.md +++ b/docs/ats/api/contracts/facets/partitions/PartitionsFacet.md @@ -152,6 +152,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/pause/Pause.md b/docs/ats/api/contracts/facets/pause/Pause.md index e7cb95bad3..9876b2d202 100644 --- a/docs/ats/api/contracts/facets/pause/Pause.md +++ b/docs/ats/api/contracts/facets/pause/Pause.md @@ -164,6 +164,20 @@ error IsUnpaused() Thrown when `unpause` is called while the token's internal pause flag is already cleared. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/pause/PauseFacet.md b/docs/ats/api/contracts/facets/pause/PauseFacet.md index 0600d337fc..dec659335d 100644 --- a/docs/ats/api/contracts/facets/pause/PauseFacet.md +++ b/docs/ats/api/contracts/facets/pause/PauseFacet.md @@ -221,6 +221,20 @@ error IsUnpaused() Thrown when `unpause` is called while the token's internal pause flag is already cleared. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/pause/PauseOperational.md b/docs/ats/api/contracts/facets/pause/PauseOperational.md index ea8b50a66d..52be0cd768 100644 --- a/docs/ats/api/contracts/facets/pause/PauseOperational.md +++ b/docs/ats/api/contracts/facets/pause/PauseOperational.md @@ -179,6 +179,20 @@ error IsUnpaused() Thrown when `unpause` is called while the token's internal pause flag is already cleared. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/principal/Principal.md b/docs/ats/api/contracts/facets/principal/Principal.md index 085f259ba9..c814178f3d 100644 --- a/docs/ats/api/contracts/facets/principal/Principal.md +++ b/docs/ats/api/contracts/facets/principal/Principal.md @@ -84,6 +84,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/principal/PrincipalFacet.md b/docs/ats/api/contracts/facets/principal/PrincipalFacet.md index 3211e5611a..84465c5014 100644 --- a/docs/ats/api/contracts/facets/principal/PrincipalFacet.md +++ b/docs/ats/api/contracts/facets/principal/PrincipalFacet.md @@ -126,6 +126,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipients.md b/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipients.md index 616e3cb582..f25a49879d 100644 --- a/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipients.md +++ b/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipients.md @@ -317,6 +317,20 @@ Thrown when an operation targets an address that is not a registered proceed rec | ---------------- | ------- | ------------------------------------------------------------ | | proceedRecipient | address | The address that was not found in the proceed-recipient set. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipientsFacet.md b/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipientsFacet.md index 08ebba6ef7..8a7266bd7e 100644 --- a/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipientsFacet.md +++ b/docs/ats/api/contracts/facets/proceedRecipients/ProceedRecipientsFacet.md @@ -357,6 +357,20 @@ Thrown when an operation targets an address that is not a registered proceed rec | ---------------- | ------- | ------------------------------------------------------------ | | proceedRecipient | address | The address that was not found in the proceed-recipient set. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartition.md b/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartition.md index 00761f2c2f..03e8b18fb2 100644 --- a/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartition.md +++ b/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartition.md @@ -194,6 +194,20 @@ _The reported sender is resolved through `EvmAccessors` for forwarding support._ | partition | bytes32 | Partition whose access requirement is not satisfied. | | sender | address | Effective caller that lacks the required role. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartitionFacet.md b/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartitionFacet.md index c16afbb05f..6d984beb51 100644 --- a/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/protectedByPartition/ProtectedByPartitionFacet.md @@ -236,6 +236,20 @@ _The reported sender is resolved through `EvmAccessors` for forwarding support._ | partition | bytes32 | Partition whose access requirement is not satisfied. | | sender | address | Effective caller that lacks the required role. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartition.md b/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartition.md index c8cba3feb7..7ab74d7402 100644 --- a/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartition.md +++ b/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartition.md @@ -483,6 +483,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartitionFacet.md b/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartitionFacet.md index 68b9de8364..ddcaccd31e 100644 --- a/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/protectedClearingByPartition/ProtectedClearingByPartitionFacet.md @@ -525,6 +525,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartition.md b/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartition.md index 4f8a4a3fc2..2f11ec0f4a 100644 --- a/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartition.md +++ b/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartition.md @@ -439,6 +439,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartitionFacet.md b/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartitionFacet.md index 4ad3cfe5cc..eb3b528f7d 100644 --- a/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/protectedClearingHoldByPartition/ProtectedClearingHoldByPartitionFacet.md @@ -481,6 +481,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartition.md b/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartition.md index dbb245598e..5264baa8da 100644 --- a/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartition.md +++ b/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartition.md @@ -343,6 +343,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartitionFacet.md b/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartitionFacet.md index f2f54b413f..7d540bf682 100644 --- a/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/protectedHoldByPartition/ProtectedHoldByPartitionFacet.md @@ -385,6 +385,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitions.md b/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitions.md index 54b9d4a451..9eda791c68 100644 --- a/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitions.md +++ b/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitions.md @@ -281,6 +281,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitionsFacet.md b/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitionsFacet.md index 938c2e372a..e56ee70f17 100644 --- a/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitionsFacet.md +++ b/docs/ats/api/contracts/facets/protectedPartitions/ProtectedPartitionsFacet.md @@ -323,6 +323,20 @@ error PartitionsAreUnProtected() Reverts when a protected-mode operation is attempted but partitions are not currently protected. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/recovery/Recovery.md b/docs/ats/api/contracts/facets/recovery/Recovery.md index 90310cc8c6..3b7ecf38f8 100644 --- a/docs/ats/api/contracts/facets/recovery/Recovery.md +++ b/docs/ats/api/contracts/facets/recovery/Recovery.md @@ -470,6 +470,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/recovery/RecoveryFacet.md b/docs/ats/api/contracts/facets/recovery/RecoveryFacet.md index ef780cbf31..4264f8d0f9 100644 --- a/docs/ats/api/contracts/facets/recovery/RecoveryFacet.md +++ b/docs/ats/api/contracts/facets/recovery/RecoveryFacet.md @@ -512,6 +512,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustment.md b/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustment.md index b8ab5d4b8a..553b02c728 100644 --- a/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustment.md +++ b/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustment.md @@ -370,6 +370,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustmentFacet.md b/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustmentFacet.md index 30455bda4a..282ea3d3f7 100644 --- a/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustmentFacet.md +++ b/docs/ats/api/contracts/facets/scheduledBalanceAdjustment/ScheduledBalanceAdjustmentFacet.md @@ -412,6 +412,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasks.md b/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasks.md index aa233b73f1..b841a0664b 100644 --- a/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasks.md +++ b/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasks.md @@ -188,6 +188,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasksFacet.md b/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasksFacet.md index 0c5aab9b09..d22b9db632 100644 --- a/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasksFacet.md +++ b/docs/ats/api/contracts/facets/scheduledCrossOrderedTasks/ScheduledCrossOrderedTasksFacet.md @@ -228,6 +228,20 @@ error IsPaused() Thrown when an operation that requires the token to be unpaused is attempted while the token is paused (own flag or any external pause contract). +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/securityHolders/SecurityHolders.md b/docs/ats/api/contracts/facets/securityHolders/SecurityHolders.md index 5a0cf83ac0..b73ffca978 100644 --- a/docs/ats/api/contracts/facets/securityHolders/SecurityHolders.md +++ b/docs/ats/api/contracts/facets/securityHolders/SecurityHolders.md @@ -99,6 +99,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/securityHolders/SecurityHoldersFacet.md b/docs/ats/api/contracts/facets/securityHolders/SecurityHoldersFacet.md index b72a9cb4aa..98aa04c4fa 100644 --- a/docs/ats/api/contracts/facets/securityHolders/SecurityHoldersFacet.md +++ b/docs/ats/api/contracts/facets/securityHolders/SecurityHoldersFacet.md @@ -139,6 +139,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshot.md b/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshot.md index ade5566add..c63aa8e18c 100644 --- a/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshot.md +++ b/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshot.md @@ -132,6 +132,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshotFacet.md b/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshotFacet.md index ae23e4870e..b643e1fad1 100644 --- a/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshotFacet.md +++ b/docs/ats/api/contracts/facets/securityHoldersAtSnapshot/SecurityHoldersAtSnapshotFacet.md @@ -174,6 +174,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/snapshots/Snapshots.md b/docs/ats/api/contracts/facets/snapshots/Snapshots.md index 8ef9dfedad..e92c6f16c4 100644 --- a/docs/ats/api/contracts/facets/snapshots/Snapshots.md +++ b/docs/ats/api/contracts/facets/snapshots/Snapshots.md @@ -209,6 +209,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/snapshots/SnapshotsFacet.md b/docs/ats/api/contracts/facets/snapshots/SnapshotsFacet.md index d550aa860f..1dbf335708 100644 --- a/docs/ats/api/contracts/facets/snapshots/SnapshotsFacet.md +++ b/docs/ats/api/contracts/facets/snapshots/SnapshotsFacet.md @@ -251,6 +251,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartition.md b/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartition.md index a292e0fd2f..8c04f79b2a 100644 --- a/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartition.md +++ b/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartition.md @@ -109,6 +109,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartitionFacet.md b/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartitionFacet.md index 4ef8410ad6..c6b15ff14a 100644 --- a/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/snapshotsByPartition/SnapshotsByPartitionFacet.md @@ -151,6 +151,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/ssiManagement/SsiManagement.md b/docs/ats/api/contracts/facets/ssiManagement/SsiManagement.md index fb5a24ea50..147ccfc778 100644 --- a/docs/ats/api/contracts/facets/ssiManagement/SsiManagement.md +++ b/docs/ats/api/contracts/facets/ssiManagement/SsiManagement.md @@ -319,6 +319,20 @@ Thrown when attempting to remove an address not present in the issuer list. | ------ | ------- | ---------------------------- | | issuer | address | The unlisted issuer address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/ssiManagement/SsiManagementFacet.md b/docs/ats/api/contracts/facets/ssiManagement/SsiManagementFacet.md index 286601b3fb..1c1550f0dd 100644 --- a/docs/ats/api/contracts/facets/ssiManagement/SsiManagementFacet.md +++ b/docs/ats/api/contracts/facets/ssiManagement/SsiManagementFacet.md @@ -361,6 +361,20 @@ Thrown when attempting to remove an address not present in the issuer list. | ------ | ------- | ---------------------------- | | issuer | address | The unlisted issuer address. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transfer/Transfer.md b/docs/ats/api/contracts/facets/transfer/Transfer.md index 389467c4d9..8576606d63 100644 --- a/docs/ats/api/contracts/facets/transfer/Transfer.md +++ b/docs/ats/api/contracts/facets/transfer/Transfer.md @@ -264,6 +264,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transfer/TransferFacet.md b/docs/ats/api/contracts/facets/transfer/TransferFacet.md index f48e8c34d7..3496f5466c 100644 --- a/docs/ats/api/contracts/facets/transfer/TransferFacet.md +++ b/docs/ats/api/contracts/facets/transfer/TransferFacet.md @@ -308,6 +308,20 @@ Reverts when a transfer is attempted while partitions are protected and the call | account | address | The caller lacking the required role. | | role | bytes32 | The role that would have been needed to proceed. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferAndLock/TransferAndLock.md b/docs/ats/api/contracts/facets/transferAndLock/TransferAndLock.md index e9d66c1258..9d648899b2 100644 --- a/docs/ats/api/contracts/facets/transferAndLock/TransferAndLock.md +++ b/docs/ats/api/contracts/facets/transferAndLock/TransferAndLock.md @@ -261,6 +261,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacet.md b/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacet.md index e1c2a7506e..183a01ccef 100644 --- a/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacet.md +++ b/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacet.md @@ -303,6 +303,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacetBase.md b/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacetBase.md index 75424735ec..88d7000257 100644 --- a/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacetBase.md +++ b/docs/ats/api/contracts/facets/transferAndLock/TransferAndLockFacetBase.md @@ -303,6 +303,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartition.md b/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartition.md index 3826a38468..f77a5f66ab 100644 --- a/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartition.md +++ b/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartition.md @@ -270,6 +270,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartitionFacet.md b/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartitionFacet.md index 02f9f3b22a..6133f70457 100644 --- a/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/transferAndLockByPartition/TransferAndLockByPartitionFacet.md @@ -312,6 +312,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferByPartition/TransferByPartition.md b/docs/ats/api/contracts/facets/transferByPartition/TransferByPartition.md index 3be20f584e..095f4b1633 100644 --- a/docs/ats/api/contracts/facets/transferByPartition/TransferByPartition.md +++ b/docs/ats/api/contracts/facets/transferByPartition/TransferByPartition.md @@ -308,6 +308,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/transferByPartition/TransferByPartitionFacet.md b/docs/ats/api/contracts/facets/transferByPartition/TransferByPartitionFacet.md index 6b9d54b234..2eea07d554 100644 --- a/docs/ats/api/contracts/facets/transferByPartition/TransferByPartitionFacet.md +++ b/docs/ats/api/contracts/facets/transferByPartition/TransferByPartitionFacet.md @@ -350,6 +350,20 @@ Thrown when the caller is not an authorised operator for the token holder on the | tokenHolder | address | Token holder whose tokens were targeted. | | partition | bytes32 | Partition on which authorisation was checked. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/voting/Voting.md b/docs/ats/api/contracts/facets/voting/Voting.md index 99c555e945..6d5156ea6f 100644 --- a/docs/ats/api/contracts/facets/voting/Voting.md +++ b/docs/ats/api/contracts/facets/voting/Voting.md @@ -309,6 +309,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VotingAlreadyRecorded ```solidity diff --git a/docs/ats/api/contracts/facets/voting/VotingFacet.md b/docs/ats/api/contracts/facets/voting/VotingFacet.md index f88a0dc947..6eea09cd13 100644 --- a/docs/ats/api/contracts/facets/voting/VotingFacet.md +++ b/docs/ats/api/contracts/facets/voting/VotingFacet.md @@ -351,6 +351,20 @@ _Replaces assertions for defensive handling of logically impossible states._ | --------- | ------ | -------------------------------------------------- | | \_errorId | bytes4 | Identifier of the unexpected validation condition. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VotingAlreadyRecorded ```solidity diff --git a/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHolders.md b/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHolders.md index 4aec73720e..82dd5df11f 100644 --- a/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHolders.md +++ b/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHolders.md @@ -132,6 +132,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHoldersFacet.md b/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHoldersFacet.md index 39b192db37..27a244ad2b 100644 --- a/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHoldersFacet.md +++ b/docs/ats/api/contracts/facets/votingSecurityHolders/VotingSecurityHoldersFacet.md @@ -174,6 +174,20 @@ error SnapshotIdNull() Thrown when a snapshot identifier of zero is supplied; zero is reserved and never assigned to a valid snapshot. +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/factory/Factory.md b/docs/ats/api/contracts/factory/Factory.md index 2469427b07..afa3e98d73 100644 --- a/docs/ats/api/contracts/factory/Factory.md +++ b/docs/ats/api/contracts/factory/Factory.md @@ -70,18 +70,17 @@ function deployEquity(IFactory.EquityData _equityData, FactoryRegulationData _fa ### deployProxy ```solidity -function deployProxy(contract IBusinessLogicResolver _resolver, bytes32 _configKey, uint256 _version, IResolverProxy.Rbac[] _rbacs, bytes _data) external nonpayable returns (address proxyAddress_) +function deployProxy(contract IBusinessLogicResolver _resolver, IResolverProxy.ResolverProxyConfigurationV2 _resolverProxyConfigurationV2, IResolverProxy.Rbac[] _rbacs, bytes _data) external nonpayable returns (address proxyAddress_) ``` #### Parameters -| Name | Type | Description | -| ----------- | ------------------------------- | ----------- | -| \_resolver | contract IBusinessLogicResolver | undefined | -| \_configKey | bytes32 | undefined | -| \_version | uint256 | undefined | -| \_rbacs | IResolverProxy.Rbac[] | undefined | -| \_data | bytes | undefined | +| Name | Type | Description | +| ------------------------------ | ------------------------------------------- | ----------- | +| \_resolver | contract IBusinessLogicResolver | undefined | +| \_resolverProxyConfigurationV2 | IResolverProxy.ResolverProxyConfigurationV2 | undefined | +| \_rbacs | IResolverProxy.Rbac[] | undefined | +| \_data | bytes | undefined | #### Returns diff --git a/docs/ats/api/contracts/factory/FactoryFacet.md b/docs/ats/api/contracts/factory/FactoryFacet.md index 7b5695bc82..d92f8709fb 100644 --- a/docs/ats/api/contracts/factory/FactoryFacet.md +++ b/docs/ats/api/contracts/factory/FactoryFacet.md @@ -70,18 +70,17 @@ function deployEquity(IFactory.EquityData _equityData, FactoryRegulationData _fa ### deployProxy ```solidity -function deployProxy(contract IBusinessLogicResolver _resolver, bytes32 _configKey, uint256 _version, IResolverProxy.Rbac[] _rbacs, bytes _data) external nonpayable returns (address proxyAddress_) +function deployProxy(contract IBusinessLogicResolver _resolver, IResolverProxy.ResolverProxyConfigurationV2 _resolverProxyConfigurationV2, IResolverProxy.Rbac[] _rbacs, bytes _data) external nonpayable returns (address proxyAddress_) ``` #### Parameters -| Name | Type | Description | -| ----------- | ------------------------------- | ----------- | -| \_resolver | contract IBusinessLogicResolver | undefined | -| \_configKey | bytes32 | undefined | -| \_version | uint256 | undefined | -| \_rbacs | IResolverProxy.Rbac[] | undefined | -| \_data | bytes | undefined | +| Name | Type | Description | +| ------------------------------ | ------------------------------------------- | ----------- | +| \_resolver | contract IBusinessLogicResolver | undefined | +| \_resolverProxyConfigurationV2 | IResolverProxy.ResolverProxyConfigurationV2 | undefined | +| \_rbacs | IResolverProxy.Rbac[] | undefined | +| \_data | bytes | undefined | #### Returns diff --git a/docs/ats/api/contracts/factory/IFactory.md b/docs/ats/api/contracts/factory/IFactory.md index c6c2552736..6b6bc78ab4 100644 --- a/docs/ats/api/contracts/factory/IFactory.md +++ b/docs/ats/api/contracts/factory/IFactory.md @@ -68,18 +68,17 @@ function deployEquity(IFactory.EquityData _equityData, FactoryRegulationData _fa ### deployProxy ```solidity -function deployProxy(contract IBusinessLogicResolver _resolver, bytes32 _configKey, uint256 _version, IResolverProxy.Rbac[] _rbacs, bytes _data) external nonpayable returns (address proxyAddress_) +function deployProxy(contract IBusinessLogicResolver _resolver, IResolverProxy.ResolverProxyConfigurationV2 _resolverProxyConfigurationV2, IResolverProxy.Rbac[] _rbacs, bytes _data) external nonpayable returns (address proxyAddress_) ``` #### Parameters -| Name | Type | Description | -| ----------- | ------------------------------- | ----------- | -| \_resolver | contract IBusinessLogicResolver | undefined | -| \_configKey | bytes32 | undefined | -| \_version | uint256 | undefined | -| \_rbacs | IResolverProxy.Rbac[] | undefined | -| \_data | bytes | undefined | +| Name | Type | Description | +| ------------------------------ | ------------------------------------------- | ----------- | +| \_resolver | contract IBusinessLogicResolver | undefined | +| \_resolverProxyConfigurationV2 | IResolverProxy.ResolverProxyConfigurationV2 | undefined | +| \_rbacs | IResolverProxy.Rbac[] | undefined | +| \_data | bytes | undefined | #### Returns diff --git a/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolver.md b/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolver.md index 7d96abe7e5..00ad9be567 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolver.md +++ b/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolver.md @@ -69,7 +69,7 @@ function cancelBatchConfiguration(bytes32 _configurationId) external nonpayable Discards an in-progress batch configuration, dropping every facet appended so far for the pending version. -_Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ +_Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ #### Parameters @@ -554,6 +554,26 @@ Returns the pending owner of a configuration, if any. | -------------- | ------- | --------------------------------------------------------------------------------------------------- | | pendingOwner\_ | address | Address currently nominated to accept ownership, or the zero address when no transfer is in flight. | +### getReplacementAddress + +```solidity +function getReplacementAddress(address _replacedAddress) external view returns (address replacementAddress_) +``` + +Returns the replacement address for a given address, or address(0) if none exists + +#### Parameters + +| Name | Type | Description | +| ----------------- | ------- | ----------- | +| \_replacedAddress | address | undefined | + +#### Returns + +| Name | Type | Description | +| -------------------- | ------- | ----------------------------------------------------- | +| replacementAddress\_ | address | the replacement address, or address(0) if none exists | + ### getRoleCountFor ```solidity @@ -830,6 +850,20 @@ function registerBusinessLogics(IBusinessLogicResolver.BusinessLogicRegistryData | ---------------- | -------------------------------------------------- | ----------- | | \_businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | undefined | +### removeReplacementAddress + +```solidity +function removeReplacementAddress(address _replacedAddress) external nonpayable +``` + +Removes the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ----------------- | ------- | ----------- | +| \_replacedAddress | address | undefined | + ### removeSelectorsFromBlacklist ```solidity @@ -912,6 +946,29 @@ Returns the business logic address for the latest version. ### resolveResolverProxyCall +```solidity +function resolveResolverProxyCall(bytes _resolverProxyConfiguration, bytes4 _selector) external view returns (address facetAddress_) +``` + +Resolves the facet address that implements a selector for a given configuration and version. + +_Used by resolver proxies during dispatch. Returns `address(0)` when no facet claims the selector._ + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------ | ----------------------------------- | +| \_resolverProxyConfiguration | bytes | Resolver proxy full configuration. | +| \_selector | bytes4 | Function selector being dispatched. | + +#### Returns + +| Name | Type | Description | +| -------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| facetAddress\_ | address | Address of the facet that owns `_selector`, or `address(0)` if the selector is not registered for the given configuration/version. | + +### resolveResolverProxyCall + ```solidity function resolveResolverProxyCall(bytes32 _configurationId, uint256 _version, bytes4 _selector) external view returns (address facetAddress_) ``` @@ -1014,6 +1071,21 @@ _Requires `ROLE_PAUSER` and the token's internal flag to be set. Reverts wit | --------- | ---- | --------------------------------------------------------- | | success\_ | bool | True if the internal pause flag was successfully cleared. | +### updateReplacementAddress + +```solidity +function updateReplacementAddress(address _replacedAddress, address _replacementAddress) external nonpayable +``` + +Updates the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| -------------------- | ------- | ----------- | +| \_replacedAddress | address | undefined | +| \_replacementAddress | address | undefined | + ## Events ### AccessControlInitialized @@ -1051,10 +1123,10 @@ Event emitted when Business Logic(s) are registered (updated or added). | businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | list of registered Business Logics. | | newLatestVersions | uint256[] | new latest version per registered key, in the same order as `businessLogics`. | -### DiamondBatchConfigurationCanceled +### DiamondBatchConfigurationCancelled ```solidity -event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version) +event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version) ``` Emitted when an in-progress batch configuration is discarded. @@ -1064,7 +1136,7 @@ Emitted when an in-progress batch configuration is discarded. | Name | Type | Description | | ------------------------- | ------- | ----------------------------------------------------------- | | configurationId `indexed` | bytes32 | Configuration key whose pending batch was cancelled. | -| version | uint256 | Version number that was being assembled and is now dropped. | +| version `indexed` | uint256 | Version number that was being assembled and is now dropped. | ### DiamondBatchConfigurationCreated @@ -1161,6 +1233,36 @@ Emitted when the token's internal pause flag is set to `true`. | ------------------ | ------- | ---------------------------------------------- | | operator `indexed` | address | Address of the caller who triggered the pause. | +### ReplacementAddressRemoved + +```solidity +event ReplacementAddressRemoved(address indexed replacedAddress, address indexed replacementAddressRemoved) +``` + +Event emitted when a replacement address is removed + +#### Parameters + +| Name | Type | Description | +| ----------------------------------- | ------- | --------------------------------------------------- | +| replacedAddress `indexed` | address | address for which the replacement is being removed. | +| replacementAddressRemoved `indexed` | address | removed replacement address. | + +### ReplacementAddressUpdated + +```solidity +event ReplacementAddressUpdated(address indexed replacedAddress, address indexed replacementAddress) +``` + +Event emitted when an old address is replaced with a new one + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------- | ---------------------------------- | +| replacedAddress `indexed` | address | old address been replaced. | +| replacementAddress `indexed` | address | new address replacing the old one. | + ### RoleGranted ```solidity @@ -1455,6 +1557,48 @@ Thrown when a configuration references a facet id that is not registered in the | configurationId | bytes32 | Configuration being created or modified. | | facetId | bytes32 | Unknown facet id that triggered the revert. | +### InvalidReplacedAddress + +```solidity +error InvalidReplacedAddress(address replacedAddress) +``` + +Thrown when a replaced address is already been used as replacement of other addresses. + +#### Parameters + +| Name | Type | Description | +| --------------- | ------- | ----------------- | +| replacedAddress | address | Replaced address. | + +### InvalidReplacementAddress + +```solidity +error InvalidReplacementAddress(address replacementAddress) +``` + +Thrown when a replacement address is already been replaced. + +#### Parameters + +| Name | Type | Description | +| ------------------ | ------- | --------------------------------------------------------------------------------------- | +| replacementAddress | address | Replacement address that is already been replaced and thus cannot replaced another one. | + +### InvalidResolverProxyConfiguration + +```solidity +error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration) +``` + +Thrown when the provided encoded proxy configuration does not respect the standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ----- | ---------------------------------- | +| \_resolverProxyConfiguration | bytes | wrong encoded proxy configuration. | + ### IsPaused ```solidity @@ -1588,6 +1732,20 @@ Indicates that a requested operation is not implemented by this resolver. _Reserved for interface compatibility or future extension points._ +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VersionZero ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.md b/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.md index 8dbfd867dc..37b271f616 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.md +++ b/docs/ats/api/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.md @@ -33,7 +33,7 @@ function cancelBatchConfiguration(bytes32 _configurationId) external nonpayable Discards an in-progress batch configuration, dropping every facet appended so far for the pending version. -_Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ +_Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ #### Parameters @@ -478,6 +478,26 @@ _Issued so off-chain consumers can avoid one `eth_call` per key — JSON-RPC rel | ---------------- | --------- | ------------------------------------------------------------------ | | latestVersions\_ | uint256[] | latest version per key, in the same order as `_businessLogicKeys`. | +### getReplacementAddress + +```solidity +function getReplacementAddress(address _oldAddress) external view returns (address replacementAddress_) +``` + +Returns the replacement address for a given address, or address(0) if none exists + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------------- | +| \_oldAddress | address | the address whose replacement is queried | + +#### Returns + +| Name | Type | Description | +| -------------------- | ------- | ----------------------------------------------------- | +| replacementAddress\_ | address | the replacement address, or address(0) if none exists | + ### getSelectorsBlacklist ```solidity @@ -568,6 +588,20 @@ function registerBusinessLogics(IBusinessLogicResolver.BusinessLogicRegistryData | ---------------- | -------------------------------------------------- | ----------- | | \_businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | undefined | +### removeReplacementAddress + +```solidity +function removeReplacementAddress(address _oldAddress) external nonpayable +``` + +Removes the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ----------------------------------------------- | +| \_oldAddress | address | the address for which to remove the replacement | + ### removeSelectorsFromBlacklist ```solidity @@ -626,6 +660,29 @@ Returns the business logic address for the latest version. ### resolveResolverProxyCall +```solidity +function resolveResolverProxyCall(bytes _resolverProxyConfiguration, bytes4 _selector) external view returns (address facetAddress_) +``` + +Resolves the facet address that implements a selector for a given configuration and version. + +_Used by resolver proxies during dispatch. Returns `address(0)` when no facet claims the selector._ + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------ | ----------------------------------- | +| \_resolverProxyConfiguration | bytes | Resolver proxy full configuration. | +| \_selector | bytes4 | Function selector being dispatched. | + +#### Returns + +| Name | Type | Description | +| -------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| facetAddress\_ | address | Address of the facet that owns `_selector`, or `address(0)` if the selector is not registered for the given configuration/version. | + +### resolveResolverProxyCall + ```solidity function resolveResolverProxyCall(bytes32 _configurationId, uint256 _version, bytes4 _selector) external view returns (address facetAddress_) ``` @@ -672,6 +729,21 @@ _Powers ERC-165 lookups on resolver proxies._ | -------- | ---- | ----------------------------------------------------------------- | | exists\_ | bool | True if `_interfaceId` is supported by the configuration version. | +### updateReplacementAddress + +```solidity +function updateReplacementAddress(address _oldAddress, address _newAddress) external nonpayable +``` + +Updates the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------- | +| \_oldAddress | address | the address to be replaced | +| \_newAddress | address | the new address to replace it with | + ## Events ### BusinessLogicResolverInitialized @@ -699,10 +771,10 @@ Event emitted when Business Logic(s) are registered (updated or added). | businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | list of registered Business Logics. | | newLatestVersions | uint256[] | new latest version per registered key, in the same order as `businessLogics`. | -### DiamondBatchConfigurationCanceled +### DiamondBatchConfigurationCancelled ```solidity -event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version) +event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version) ``` Emitted when an in-progress batch configuration is discarded. @@ -712,7 +784,7 @@ Emitted when an in-progress batch configuration is discarded. | Name | Type | Description | | ------------------------- | ------- | ----------------------------------------------------------- | | configurationId `indexed` | bytes32 | Configuration key whose pending batch was cancelled. | -| version | uint256 | Version number that was being assembled and is now dropped. | +| version `indexed` | uint256 | Version number that was being assembled and is now dropped. | ### DiamondBatchConfigurationCreated @@ -749,6 +821,36 @@ Emitted when a configuration is created atomically via {createConfiguration}. | version | uint256 | Version number assigned to the newly created configuration. | | data | bytes | Additional data passed to the configuration. | +### ReplacementAddressRemoved + +```solidity +event ReplacementAddressRemoved(address indexed replacedAddress, address indexed replacementAddressRemoved) +``` + +Event emitted when a replacement address is removed + +#### Parameters + +| Name | Type | Description | +| ----------------------------------- | ------- | --------------------------------------------------- | +| replacedAddress `indexed` | address | address for which the replacement is being removed. | +| replacementAddressRemoved `indexed` | address | removed replacement address. | + +### ReplacementAddressUpdated + +```solidity +event ReplacementAddressUpdated(address indexed replacedAddress, address indexed replacementAddress) +``` + +Event emitted when an old address is replaced with a new one + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------- | ---------------------------------- | +| replacedAddress `indexed` | address | old address been replaced. | +| replacementAddress `indexed` | address | new address replacing the old one. | + ## Errors ### BusinessLogicKeyDuplicated @@ -846,6 +948,48 @@ Thrown when a configuration references a facet id that is not registered in the | configurationId | bytes32 | Configuration being created or modified. | | facetId | bytes32 | Unknown facet id that triggered the revert. | +### InvalidReplacedAddress + +```solidity +error InvalidReplacedAddress(address replacedAddress) +``` + +Thrown when a replaced address is already been used as replacement of other addresses. + +#### Parameters + +| Name | Type | Description | +| --------------- | ------- | ----------------- | +| replacedAddress | address | Replaced address. | + +### InvalidReplacementAddress + +```solidity +error InvalidReplacementAddress(address replacementAddress) +``` + +Thrown when a replacement address is already been replaced. + +#### Parameters + +| Name | Type | Description | +| ------------------ | ------- | --------------------------------------------------------------------------------------- | +| replacementAddress | address | Replacement address that is already been replaced and thus cannot replaced another one. | + +### InvalidResolverProxyConfiguration + +```solidity +error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration) +``` + +Thrown when the provided encoded proxy configuration does not respect the standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ----- | ---------------------------------- | +| \_resolverProxyConfiguration | bytes | wrong encoded proxy configuration. | + ### OngoingBatchConfigurationNotPermitted ```solidity @@ -906,6 +1050,20 @@ Thrown when attempting to register a selector that is globally blacklisted. | -------- | ------ | ------------------------------------ | | selector | bytes4 | Function selector that is forbidden. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VersionZero ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/DiamondBase.md b/docs/ats/api/contracts/infrastructure/diamond/DiamondBase.md index a777940f66..69cbea4756 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/DiamondBase.md +++ b/docs/ats/api/contracts/infrastructure/diamond/DiamondBase.md @@ -13,18 +13,20 @@ _Inherits from existing DiamondCut and DiamondLoupe abstracts and adds the initi ### getConfigInfo ```solidity -function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_) +function getConfigInfo() external view returns (address resolver_, bytes8 proxyVersion_, bytes32 configurationId_, uint256 configurationVersion_, bool replacementEnabled_) ``` Returns the active resolver address, configuration identifier, and version. #### Returns -| Name | Type | Description | -| ----------------- | ------- | ----------------------------------------------- | -| resolver\_ | address | Address of the current Business Logic Resolver. | -| configurationId\_ | bytes32 | Identifier of the active configuration. | -| version\_ | uint256 | Version number of the active configuration. | +| Name | Type | Description | +| ---------------------- | ------- | ----------------------------------------------- | +| resolver\_ | address | Address of the current Business Logic Resolver. | +| proxyVersion\_ | bytes8 | proxy version. | +| configurationId\_ | bytes32 | Identifier of the active configuration. | +| configurationVersion\_ | uint256 | Version number of the active configuration. | +| replacementEnabled\_ | bool | Whether replacement is enabled. | ### getFacet @@ -378,10 +380,24 @@ _Requires `DEFAULT_ADMIN_ROLE` and preserves the active configuration identifier | ------------ | ------- | ------------------------------------------------------------ | | \_newVersion | uint256 | The new version number to set for the current configuration. | +### updateReplacementEnabled + +```solidity +function updateReplacementEnabled(bool _newReplacementEnabled) external nonpayable +``` + +For the current BLR update its configuration + +#### Parameters + +| Name | Type | Description | +| ----------------------- | ---- | ------------------------------------- | +| \_newReplacementEnabled | bool | The replacement enabled flag to set\* | + ### updateResolver ```solidity -function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion) external nonpayable +function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion, bool _newReplacementEnabled) external nonpayable ``` Replaces the Business Logic Resolver with a new one, setting configuration and version. @@ -390,11 +406,12 @@ _Requires `DEFAULT_ADMIN_ROLE` and validates the target configuration against th #### Parameters -| Name | Type | Description | -| -------------------- | ------------------------------- | ------------------------------------------------------------- | -| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | -| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | -| \_newVersion | uint256 | The version number associated with the new configuration. | +| Name | Type | Description | +| ----------------------- | ------------------------------- | ------------------------------------------------------------- | +| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | +| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | +| \_newVersion | uint256 | The version number associated with the new configuration. | +| \_newReplacementEnabled | bool | The replacement enabled flag to set. | ## Events @@ -440,6 +457,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/DiamondCut.md b/docs/ats/api/contracts/infrastructure/diamond/DiamondCut.md index 6bbea32a43..a73235c508 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/DiamondCut.md +++ b/docs/ats/api/contracts/infrastructure/diamond/DiamondCut.md @@ -13,18 +13,20 @@ _Mutates resolver-proxy storage after validating target configurations through t ### getConfigInfo ```solidity -function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_) +function getConfigInfo() external view returns (address resolver_, bytes8 proxyVersion_, bytes32 configurationId_, uint256 configurationVersion_, bool replacementEnabled_) ``` Returns the active resolver address, configuration identifier, and version. #### Returns -| Name | Type | Description | -| ----------------- | ------- | ----------------------------------------------- | -| resolver\_ | address | Address of the current Business Logic Resolver. | -| configurationId\_ | bytes32 | Identifier of the active configuration. | -| version\_ | uint256 | Version number of the active configuration. | +| Name | Type | Description | +| ---------------------- | ------- | ----------------------------------------------- | +| resolver\_ | address | Address of the current Business Logic Resolver. | +| proxyVersion\_ | bytes8 | proxy version. | +| configurationId\_ | bytes32 | Identifier of the active configuration. | +| configurationVersion\_ | uint256 | Version number of the active configuration. | +| replacementEnabled\_ | bool | Whether replacement is enabled. | ### getStaticFunctionSelectors @@ -101,10 +103,24 @@ _Requires `DEFAULT_ADMIN_ROLE` and preserves the active configuration identifier | ------------ | ------- | ------------------------------------------------------------ | | \_newVersion | uint256 | The new version number to set for the current configuration. | +### updateReplacementEnabled + +```solidity +function updateReplacementEnabled(bool _newReplacementEnabled) external nonpayable +``` + +For the current BLR update its configuration + +#### Parameters + +| Name | Type | Description | +| ----------------------- | ---- | ------------------------------------- | +| \_newReplacementEnabled | bool | The replacement enabled flag to set\* | + ### updateResolver ```solidity -function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion) external nonpayable +function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion, bool _newReplacementEnabled) external nonpayable ``` Replaces the Business Logic Resolver with a new one, setting configuration and version. @@ -113,11 +129,12 @@ _Requires `DEFAULT_ADMIN_ROLE` and validates the target configuration against th #### Parameters -| Name | Type | Description | -| -------------------- | ------------------------------- | ------------------------------------------------------------- | -| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | -| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | -| \_newVersion | uint256 | The version number associated with the new configuration. | +| Name | Type | Description | +| ----------------------- | ------------------------------- | ------------------------------------------------------------- | +| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | +| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | +| \_newVersion | uint256 | The version number associated with the new configuration. | +| \_newReplacementEnabled | bool | The replacement enabled flag to set. | ## Errors @@ -136,6 +153,20 @@ Thrown when an account does not hold a required role. | account | address | The account that lacks the role. | | role | bytes32 | The role that is not held. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManager.md b/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManager.md index 8d43f0ffca..cdb96a2541 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManager.md +++ b/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManager.md @@ -67,7 +67,7 @@ function cancelBatchConfiguration(bytes32 _configurationId) external nonpayable Discards an in-progress batch configuration, dropping every facet appended so far for the pending version. -_Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ +_Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ #### Parameters @@ -552,6 +552,26 @@ Returns the pending owner of a configuration, if any. | -------------- | ------- | --------------------------------------------------------------------------------------------------- | | pendingOwner\_ | address | Address currently nominated to accept ownership, or the zero address when no transfer is in flight. | +### getReplacementAddress + +```solidity +function getReplacementAddress(address _oldAddress) external view returns (address replacementAddress_) +``` + +Returns the replacement address for a given address, or address(0) if none exists + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------------- | +| \_oldAddress | address | the address whose replacement is queried | + +#### Returns + +| Name | Type | Description | +| -------------------- | ------- | ----------------------------------------------------- | +| replacementAddress\_ | address | the replacement address, or address(0) if none exists | + ### getRoleCountFor ```solidity @@ -826,6 +846,20 @@ function registerBusinessLogics(IBusinessLogicResolver.BusinessLogicRegistryData | ---------------- | -------------------------------------------------- | ----------- | | \_businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | undefined | +### removeReplacementAddress + +```solidity +function removeReplacementAddress(address _oldAddress) external nonpayable +``` + +Removes the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ----------------------------------------------- | +| \_oldAddress | address | the address for which to remove the replacement | + ### removeSelectorsFromBlacklist ```solidity @@ -906,6 +940,29 @@ Returns the business logic address for the latest version. ### resolveResolverProxyCall +```solidity +function resolveResolverProxyCall(bytes _resolverProxyConfiguration, bytes4 _selector) external view returns (address facetAddress_) +``` + +Resolves the facet address that implements a selector for a given configuration and version. + +_Used by resolver proxies during dispatch. Returns `address(0)` when no facet claims the selector._ + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------ | ----------------------------------- | +| \_resolverProxyConfiguration | bytes | Resolver proxy full configuration. | +| \_selector | bytes4 | Function selector being dispatched. | + +#### Returns + +| Name | Type | Description | +| -------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| facetAddress\_ | address | Address of the facet that owns `_selector`, or `address(0)` if the selector is not registered for the given configuration/version. | + +### resolveResolverProxyCall + ```solidity function resolveResolverProxyCall(bytes32 _configurationId, uint256 _version, bytes4 _selector) external view returns (address facetAddress_) ``` @@ -1008,6 +1065,21 @@ _Requires `ROLE_PAUSER` and the token's internal flag to be set. Reverts wit | --------- | ---- | --------------------------------------------------------- | | success\_ | bool | True if the internal pause flag was successfully cleared. | +### updateReplacementAddress + +```solidity +function updateReplacementAddress(address _oldAddress, address _newAddress) external nonpayable +``` + +Updates the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------- | +| \_oldAddress | address | the address to be replaced | +| \_newAddress | address | the new address to replace it with | + ## Events ### AccessControlInitialized @@ -1045,10 +1117,10 @@ Event emitted when Business Logic(s) are registered (updated or added). | businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | list of registered Business Logics. | | newLatestVersions | uint256[] | new latest version per registered key, in the same order as `businessLogics`. | -### DiamondBatchConfigurationCanceled +### DiamondBatchConfigurationCancelled ```solidity -event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version) +event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version) ``` Emitted when an in-progress batch configuration is discarded. @@ -1058,7 +1130,7 @@ Emitted when an in-progress batch configuration is discarded. | Name | Type | Description | | ------------------------- | ------- | ----------------------------------------------------------- | | configurationId `indexed` | bytes32 | Configuration key whose pending batch was cancelled. | -| version | uint256 | Version number that was being assembled and is now dropped. | +| version `indexed` | uint256 | Version number that was being assembled and is now dropped. | ### DiamondBatchConfigurationCreated @@ -1155,6 +1227,36 @@ Emitted when the token's internal pause flag is set to `true`. | ------------------ | ------- | ---------------------------------------------- | | operator `indexed` | address | Address of the caller who triggered the pause. | +### ReplacementAddressRemoved + +```solidity +event ReplacementAddressRemoved(address indexed replacedAddress, address indexed replacementAddressRemoved) +``` + +Event emitted when a replacement address is removed + +#### Parameters + +| Name | Type | Description | +| ----------------------------------- | ------- | --------------------------------------------------- | +| replacedAddress `indexed` | address | address for which the replacement is being removed. | +| replacementAddressRemoved `indexed` | address | removed replacement address. | + +### ReplacementAddressUpdated + +```solidity +event ReplacementAddressUpdated(address indexed replacedAddress, address indexed replacementAddress) +``` + +Event emitted when an old address is replaced with a new one + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------- | ---------------------------------- | +| replacedAddress `indexed` | address | old address been replaced. | +| replacementAddress `indexed` | address | new address replacing the old one. | + ### RoleGranted ```solidity @@ -1439,6 +1541,48 @@ Thrown when a configuration references a facet id that is not registered in the | configurationId | bytes32 | Configuration being created or modified. | | facetId | bytes32 | Unknown facet id that triggered the revert. | +### InvalidReplacedAddress + +```solidity +error InvalidReplacedAddress(address replacedAddress) +``` + +Thrown when a replaced address is already been used as replacement of other addresses. + +#### Parameters + +| Name | Type | Description | +| --------------- | ------- | ----------------- | +| replacedAddress | address | Replaced address. | + +### InvalidReplacementAddress + +```solidity +error InvalidReplacementAddress(address replacementAddress) +``` + +Thrown when a replacement address is already been replaced. + +#### Parameters + +| Name | Type | Description | +| ------------------ | ------- | --------------------------------------------------------------------------------------- | +| replacementAddress | address | Replacement address that is already been replaced and thus cannot replaced another one. | + +### InvalidResolverProxyConfiguration + +```solidity +error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration) +``` + +Thrown when the provided encoded proxy configuration does not respect the standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ----- | ---------------------------------- | +| \_resolverProxyConfiguration | bytes | wrong encoded proxy configuration. | + ### IsPaused ```solidity @@ -1562,6 +1706,20 @@ Thrown when attempting to register a selector that is globally blacklisted. | -------- | ------ | ------------------------------------ | | selector | bytes4 | Function selector that is forbidden. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VersionZero ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManagerWrapper.md b/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManagerWrapper.md index 727b309c63..8ed7351de0 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManagerWrapper.md +++ b/docs/ats/api/contracts/infrastructure/diamond/DiamondCutManagerWrapper.md @@ -49,7 +49,7 @@ function cancelBatchConfiguration(bytes32 _configurationId) external nonpayable Discards an in-progress batch configuration, dropping every facet appended so far for the pending version. -_Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ +_Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ #### Parameters @@ -534,6 +534,26 @@ Returns the pending owner of a configuration, if any. | -------------- | ------- | --------------------------------------------------------------------------------------------------- | | pendingOwner\_ | address | Address currently nominated to accept ownership, or the zero address when no transfer is in flight. | +### getReplacementAddress + +```solidity +function getReplacementAddress(address _oldAddress) external view returns (address replacementAddress_) +``` + +Returns the replacement address for a given address, or address(0) if none exists + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------------- | +| \_oldAddress | address | the address whose replacement is queried | + +#### Returns + +| Name | Type | Description | +| -------------------- | ------- | ----------------------------------------------------- | +| replacementAddress\_ | address | the replacement address, or address(0) if none exists | + ### getSelectorsBlacklist ```solidity @@ -666,6 +686,20 @@ function registerBusinessLogics(IBusinessLogicResolver.BusinessLogicRegistryData | ---------------- | -------------------------------------------------- | ----------- | | \_businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | undefined | +### removeReplacementAddress + +```solidity +function removeReplacementAddress(address _oldAddress) external nonpayable +``` + +Removes the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ----------------------------------------------- | +| \_oldAddress | address | the address for which to remove the replacement | + ### removeSelectorsFromBlacklist ```solidity @@ -724,6 +758,29 @@ Returns the business logic address for the latest version. ### resolveResolverProxyCall +```solidity +function resolveResolverProxyCall(bytes _resolverProxyConfiguration, bytes4 _selector) external view returns (address facetAddress_) +``` + +Resolves the facet address that implements a selector for a given configuration and version. + +_Used by resolver proxies during dispatch. Returns `address(0)` when no facet claims the selector._ + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------ | ----------------------------------- | +| \_resolverProxyConfiguration | bytes | Resolver proxy full configuration. | +| \_selector | bytes4 | Function selector being dispatched. | + +#### Returns + +| Name | Type | Description | +| -------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| facetAddress\_ | address | Address of the facet that owns `_selector`, or `address(0)` if the selector is not registered for the given configuration/version. | + +### resolveResolverProxyCall + ```solidity function resolveResolverProxyCall(bytes32 _configurationId, uint256 _version, bytes4 _selector) external view returns (address facetAddress_) ``` @@ -803,6 +860,21 @@ _Requires `ROLE_PAUSER` and the token's internal flag to be set. Reverts wit | --------- | ---- | --------------------------------------------------------- | | success\_ | bool | True if the internal pause flag was successfully cleared. | +### updateReplacementAddress + +```solidity +function updateReplacementAddress(address _oldAddress, address _newAddress) external nonpayable +``` + +Updates the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------- | +| \_oldAddress | address | the address to be replaced | +| \_newAddress | address | the new address to replace it with | + ## Events ### BusinessLogicResolverInitialized @@ -830,10 +902,10 @@ Event emitted when Business Logic(s) are registered (updated or added). | businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | list of registered Business Logics. | | newLatestVersions | uint256[] | new latest version per registered key, in the same order as `businessLogics`. | -### DiamondBatchConfigurationCanceled +### DiamondBatchConfigurationCancelled ```solidity -event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version) +event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version) ``` Emitted when an in-progress batch configuration is discarded. @@ -843,7 +915,7 @@ Emitted when an in-progress batch configuration is discarded. | Name | Type | Description | | ------------------------- | ------- | ----------------------------------------------------------- | | configurationId `indexed` | bytes32 | Configuration key whose pending batch was cancelled. | -| version | uint256 | Version number that was being assembled and is now dropped. | +| version `indexed` | uint256 | Version number that was being assembled and is now dropped. | ### DiamondBatchConfigurationCreated @@ -940,6 +1012,36 @@ Emitted when the token's internal pause flag is set to `true`. | ------------------ | ------- | ---------------------------------------------- | | operator `indexed` | address | Address of the caller who triggered the pause. | +### ReplacementAddressRemoved + +```solidity +event ReplacementAddressRemoved(address indexed replacedAddress, address indexed replacementAddressRemoved) +``` + +Event emitted when a replacement address is removed + +#### Parameters + +| Name | Type | Description | +| ----------------------------------- | ------- | --------------------------------------------------- | +| replacedAddress `indexed` | address | address for which the replacement is being removed. | +| replacementAddressRemoved `indexed` | address | removed replacement address. | + +### ReplacementAddressUpdated + +```solidity +event ReplacementAddressUpdated(address indexed replacedAddress, address indexed replacementAddress) +``` + +Event emitted when an old address is replaced with a new one + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------- | ---------------------------------- | +| replacedAddress `indexed` | address | old address been replaced. | +| replacementAddress `indexed` | address | new address replacing the old one. | + ### Unpaused ```solidity @@ -1089,6 +1191,48 @@ Thrown when a configuration references a facet id that is not registered in the | configurationId | bytes32 | Configuration being created or modified. | | facetId | bytes32 | Unknown facet id that triggered the revert. | +### InvalidReplacedAddress + +```solidity +error InvalidReplacedAddress(address replacedAddress) +``` + +Thrown when a replaced address is already been used as replacement of other addresses. + +#### Parameters + +| Name | Type | Description | +| --------------- | ------- | ----------------- | +| replacedAddress | address | Replaced address. | + +### InvalidReplacementAddress + +```solidity +error InvalidReplacementAddress(address replacementAddress) +``` + +Thrown when a replacement address is already been replaced. + +#### Parameters + +| Name | Type | Description | +| ------------------ | ------- | --------------------------------------------------------------------------------------- | +| replacementAddress | address | Replacement address that is already been replaced and thus cannot replaced another one. | + +### InvalidResolverProxyConfiguration + +```solidity +error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration) +``` + +Thrown when the provided encoded proxy configuration does not respect the standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ----- | ---------------------------------- | +| \_resolverProxyConfiguration | bytes | wrong encoded proxy configuration. | + ### IsPaused ```solidity @@ -1197,6 +1341,20 @@ Thrown when attempting to register a selector that is globally blacklisted. | -------- | ------ | ------------------------------------ | | selector | bytes4 | Function selector that is forbidden. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VersionZero ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/DiamondFacet.md b/docs/ats/api/contracts/infrastructure/diamond/DiamondFacet.md index 28207d5f9a..9966dda169 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/DiamondFacet.md +++ b/docs/ats/api/contracts/infrastructure/diamond/DiamondFacet.md @@ -13,18 +13,20 @@ _Provides static resolver metadata for the core Diamond facet under `RESOLVER_KE ### getConfigInfo ```solidity -function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_) +function getConfigInfo() external view returns (address resolver_, bytes8 proxyVersion_, bytes32 configurationId_, uint256 configurationVersion_, bool replacementEnabled_) ``` Returns the active resolver address, configuration identifier, and version. #### Returns -| Name | Type | Description | -| ----------------- | ------- | ----------------------------------------------- | -| resolver\_ | address | Address of the current Business Logic Resolver. | -| configurationId\_ | bytes32 | Identifier of the active configuration. | -| version\_ | uint256 | Version number of the active configuration. | +| Name | Type | Description | +| ---------------------- | ------- | ----------------------------------------------- | +| resolver\_ | address | Address of the current Business Logic Resolver. | +| proxyVersion\_ | bytes8 | proxy version. | +| configurationId\_ | bytes32 | Identifier of the active configuration. | +| configurationVersion\_ | uint256 | Version number of the active configuration. | +| replacementEnabled\_ | bool | Whether replacement is enabled. | ### getFacet @@ -382,10 +384,24 @@ _Requires `DEFAULT_ADMIN_ROLE` and preserves the active configuration identifier | ------------ | ------- | ------------------------------------------------------------ | | \_newVersion | uint256 | The new version number to set for the current configuration. | +### updateReplacementEnabled + +```solidity +function updateReplacementEnabled(bool _newReplacementEnabled) external nonpayable +``` + +For the current BLR update its configuration + +#### Parameters + +| Name | Type | Description | +| ----------------------- | ---- | ------------------------------------- | +| \_newReplacementEnabled | bool | The replacement enabled flag to set\* | + ### updateResolver ```solidity -function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion) external nonpayable +function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion, bool _newReplacementEnabled) external nonpayable ``` Replaces the Business Logic Resolver with a new one, setting configuration and version. @@ -394,11 +410,12 @@ _Requires `DEFAULT_ADMIN_ROLE` and validates the target configuration against th #### Parameters -| Name | Type | Description | -| -------------------- | ------------------------------- | ------------------------------------------------------------- | -| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | -| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | -| \_newVersion | uint256 | The version number associated with the new configuration. | +| Name | Type | Description | +| ----------------------- | ------------------------------- | ------------------------------------------------------------- | +| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | +| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | +| \_newVersion | uint256 | The version number associated with the new configuration. | +| \_newReplacementEnabled | bool | The replacement enabled flag to set. | ## Events @@ -444,6 +461,20 @@ Raised when an initialiser tries to register a facet that already has a non-zero | facetId | bytes32 | Identifier of the offending facet. | | lastVersion | uint256 | Last version recorded for that facet at the time of the check. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/DiamondLoupe.md b/docs/ats/api/contracts/infrastructure/diamond/DiamondLoupe.md index 766ea7db09..25ea398108 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/DiamondLoupe.md +++ b/docs/ats/api/contracts/infrastructure/diamond/DiamondLoupe.md @@ -318,3 +318,19 @@ _Returns true if this contract implements the interface defined by `interfaceId` | Name | Type | Description | | ---- | ---- | ----------- | | \_0 | bool | undefined | + +## Errors + +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | diff --git a/docs/ats/api/contracts/infrastructure/diamond/IBusinessLogicResolver.md b/docs/ats/api/contracts/infrastructure/diamond/IBusinessLogicResolver.md index d15f081792..bf0ea68b69 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/IBusinessLogicResolver.md +++ b/docs/ats/api/contracts/infrastructure/diamond/IBusinessLogicResolver.md @@ -31,7 +31,7 @@ function cancelBatchConfiguration(bytes32 _configurationId) external nonpayable Discards an in-progress batch configuration, dropping every facet appended so far for the pending version. -_Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ +_Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ #### Parameters @@ -476,6 +476,26 @@ _Issued so off-chain consumers can avoid one `eth_call` per key — JSON-RPC rel | ---------------- | --------- | ------------------------------------------------------------------ | | latestVersions\_ | uint256[] | latest version per key, in the same order as `_businessLogicKeys`. | +### getReplacementAddress + +```solidity +function getReplacementAddress(address _oldAddress) external view returns (address replacementAddress_) +``` + +Returns the replacement address for a given address, or address(0) if none exists + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------------- | +| \_oldAddress | address | the address whose replacement is queried | + +#### Returns + +| Name | Type | Description | +| -------------------- | ------- | ----------------------------------------------------- | +| replacementAddress\_ | address | the replacement address, or address(0) if none exists | + ### getSelectorsBlacklist ```solidity @@ -566,6 +586,20 @@ function registerBusinessLogics(IBusinessLogicResolver.BusinessLogicRegistryData | ---------------- | -------------------------------------------------- | ----------- | | \_businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | undefined | +### removeReplacementAddress + +```solidity +function removeReplacementAddress(address _oldAddress) external nonpayable +``` + +Removes the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ----------------------------------------------- | +| \_oldAddress | address | the address for which to remove the replacement | + ### removeSelectorsFromBlacklist ```solidity @@ -624,6 +658,29 @@ Returns the business logic address for the latest version. ### resolveResolverProxyCall +```solidity +function resolveResolverProxyCall(bytes _resolverProxyConfiguration, bytes4 _selector) external view returns (address facetAddress_) +``` + +Resolves the facet address that implements a selector for a given configuration and version. + +_Used by resolver proxies during dispatch. Returns `address(0)` when no facet claims the selector._ + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------ | ----------------------------------- | +| \_resolverProxyConfiguration | bytes | Resolver proxy full configuration. | +| \_selector | bytes4 | Function selector being dispatched. | + +#### Returns + +| Name | Type | Description | +| -------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| facetAddress\_ | address | Address of the facet that owns `_selector`, or `address(0)` if the selector is not registered for the given configuration/version. | + +### resolveResolverProxyCall + ```solidity function resolveResolverProxyCall(bytes32 _configurationId, uint256 _version, bytes4 _selector) external view returns (address facetAddress_) ``` @@ -670,6 +727,21 @@ _Powers ERC-165 lookups on resolver proxies._ | -------- | ---- | ----------------------------------------------------------------- | | exists\_ | bool | True if `_interfaceId` is supported by the configuration version. | +### updateReplacementAddress + +```solidity +function updateReplacementAddress(address _oldAddress, address _newAddress) external nonpayable +``` + +Updates the replacement address for a given address + +#### Parameters + +| Name | Type | Description | +| ------------ | ------- | ---------------------------------- | +| \_oldAddress | address | the address to be replaced | +| \_newAddress | address | the new address to replace it with | + ## Events ### BusinessLogicResolverInitialized @@ -697,10 +769,10 @@ Event emitted when Business Logic(s) are registered (updated or added). | businessLogics | IBusinessLogicResolver.BusinessLogicRegistryData[] | list of registered Business Logics. | | newLatestVersions | uint256[] | new latest version per registered key, in the same order as `businessLogics`. | -### DiamondBatchConfigurationCanceled +### DiamondBatchConfigurationCancelled ```solidity -event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version) +event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version) ``` Emitted when an in-progress batch configuration is discarded. @@ -710,7 +782,7 @@ Emitted when an in-progress batch configuration is discarded. | Name | Type | Description | | ------------------------- | ------- | ----------------------------------------------------------- | | configurationId `indexed` | bytes32 | Configuration key whose pending batch was cancelled. | -| version | uint256 | Version number that was being assembled and is now dropped. | +| version `indexed` | uint256 | Version number that was being assembled and is now dropped. | ### DiamondBatchConfigurationCreated @@ -747,6 +819,36 @@ Emitted when a configuration is created atomically via {createConfiguration}. | version | uint256 | Version number assigned to the newly created configuration. | | data | bytes | Additional data passed to the configuration. | +### ReplacementAddressRemoved + +```solidity +event ReplacementAddressRemoved(address indexed replacedAddress, address indexed replacementAddressRemoved) +``` + +Event emitted when a replacement address is removed + +#### Parameters + +| Name | Type | Description | +| ----------------------------------- | ------- | --------------------------------------------------- | +| replacedAddress `indexed` | address | address for which the replacement is being removed. | +| replacementAddressRemoved `indexed` | address | removed replacement address. | + +### ReplacementAddressUpdated + +```solidity +event ReplacementAddressUpdated(address indexed replacedAddress, address indexed replacementAddress) +``` + +Event emitted when an old address is replaced with a new one + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------- | ---------------------------------- | +| replacedAddress `indexed` | address | old address been replaced. | +| replacementAddress `indexed` | address | new address replacing the old one. | + ## Errors ### BusinessLogicKeyDuplicated @@ -844,6 +946,48 @@ Thrown when a configuration references a facet id that is not registered in the | configurationId | bytes32 | Configuration being created or modified. | | facetId | bytes32 | Unknown facet id that triggered the revert. | +### InvalidReplacedAddress + +```solidity +error InvalidReplacedAddress(address replacedAddress) +``` + +Thrown when a replaced address is already been used as replacement of other addresses. + +#### Parameters + +| Name | Type | Description | +| --------------- | ------- | ----------------- | +| replacedAddress | address | Replaced address. | + +### InvalidReplacementAddress + +```solidity +error InvalidReplacementAddress(address replacementAddress) +``` + +Thrown when a replacement address is already been replaced. + +#### Parameters + +| Name | Type | Description | +| ------------------ | ------- | --------------------------------------------------------------------------------------- | +| replacementAddress | address | Replacement address that is already been replaced and thus cannot replaced another one. | + +### InvalidResolverProxyConfiguration + +```solidity +error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration) +``` + +Thrown when the provided encoded proxy configuration does not respect the standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ----- | ---------------------------------- | +| \_resolverProxyConfiguration | bytes | wrong encoded proxy configuration. | + ### OngoingBatchConfigurationNotPermitted ```solidity @@ -904,6 +1048,20 @@ Thrown when attempting to register a selector that is globally blacklisted. | -------- | ------ | ------------------------------------ | | selector | bytes4 | Function selector that is forbidden. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VersionZero ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/IDiamondCutManager.md b/docs/ats/api/contracts/infrastructure/diamond/IDiamondCutManager.md index 14586aa3ec..e705b7d859 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/IDiamondCutManager.md +++ b/docs/ats/api/contracts/infrastructure/diamond/IDiamondCutManager.md @@ -18,7 +18,7 @@ function cancelBatchConfiguration(bytes32 _configurationId) external nonpayable Discards an in-progress batch configuration, dropping every facet appended so far for the pending version. -_Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ +_Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has been finalised via a `_isLastBatch = true` call._ #### Parameters @@ -409,6 +409,29 @@ Non-reverting variant of {checkResolverProxyConfigurationRegistered}. ### resolveResolverProxyCall +```solidity +function resolveResolverProxyCall(bytes _resolverProxyConfiguration, bytes4 _selector) external view returns (address facetAddress_) +``` + +Resolves the facet address that implements a selector for a given configuration and version. + +_Used by resolver proxies during dispatch. Returns `address(0)` when no facet claims the selector._ + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ------ | ----------------------------------- | +| \_resolverProxyConfiguration | bytes | Resolver proxy full configuration. | +| \_selector | bytes4 | Function selector being dispatched. | + +#### Returns + +| Name | Type | Description | +| -------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| facetAddress\_ | address | Address of the facet that owns `_selector`, or `address(0)` if the selector is not registered for the given configuration/version. | + +### resolveResolverProxyCall + ```solidity function resolveResolverProxyCall(bytes32 _configurationId, uint256 _version, bytes4 _selector) external view returns (address facetAddress_) ``` @@ -457,10 +480,10 @@ _Powers ERC-165 lookups on resolver proxies._ ## Events -### DiamondBatchConfigurationCanceled +### DiamondBatchConfigurationCancelled ```solidity -event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version) +event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version) ``` Emitted when an in-progress batch configuration is discarded. @@ -470,7 +493,7 @@ Emitted when an in-progress batch configuration is discarded. | Name | Type | Description | | ------------------------- | ------- | ----------------------------------------------------------- | | configurationId `indexed` | bytes32 | Configuration key whose pending batch was cancelled. | -| version | uint256 | Version number that was being assembled and is now dropped. | +| version `indexed` | uint256 | Version number that was being assembled and is now dropped. | ### DiamondBatchConfigurationCreated @@ -560,6 +583,20 @@ Thrown when a configuration references a facet id that is not registered in the | configurationId | bytes32 | Configuration being created or modified. | | facetId | bytes32 | Unknown facet id that triggered the revert. | +### InvalidResolverProxyConfiguration + +```solidity +error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration) +``` + +Thrown when the provided encoded proxy configuration does not respect the standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------------- | ----- | ---------------------------------- | +| \_resolverProxyConfiguration | bytes | wrong encoded proxy configuration. | + ### OngoingBatchConfigurationNotPermitted ```solidity @@ -620,6 +657,20 @@ Thrown when attempting to register a selector that is globally blacklisted. | -------- | ------ | ------------------------------------ | | selector | bytes4 | Function selector that is forbidden. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### VersionZero ```solidity diff --git a/docs/ats/api/contracts/infrastructure/diamond/Ownership.md b/docs/ats/api/contracts/infrastructure/diamond/Ownership.md index b8aa6b6a3d..ec447db295 100644 --- a/docs/ats/api/contracts/infrastructure/diamond/Ownership.md +++ b/docs/ats/api/contracts/infrastructure/diamond/Ownership.md @@ -305,6 +305,20 @@ Raised when the caller is not the pending owner of the configuration. | sender | address | Caller that attempted to accept ownership. | | pendingOwner | address | Address currently nominated as pending owner of `configId`. | +### UnrecognizedResolverProxyVersion + +```solidity +error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion) +``` + +Thrown when the provided proxy version does not match any BLR compatible standard. + +#### Parameters + +| Name | Type | Description | +| ---------------------- | ------ | -------------------------------------------------- | +| \_resolverProxyVersion | bytes8 | proxy version that is not compatible with the BLR. | + ### WalletRecovered ```solidity diff --git a/docs/ats/api/contracts/infrastructure/proxy/IDiamond.md b/docs/ats/api/contracts/infrastructure/proxy/IDiamond.md index 9753544933..4f9338c882 100644 --- a/docs/ats/api/contracts/infrastructure/proxy/IDiamond.md +++ b/docs/ats/api/contracts/infrastructure/proxy/IDiamond.md @@ -13,18 +13,20 @@ _Inherits `IDiamondCut` (facet upgrade operations) and `IDiamondLoupe` (introspe ### getConfigInfo ```solidity -function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_) +function getConfigInfo() external view returns (address resolver_, bytes8 proxyVersion_, bytes32 configurationId_, uint256 configurationVersion_, bool replacementEnabled_) ``` Returns the active resolver address, configuration identifier, and version. #### Returns -| Name | Type | Description | -| ----------------- | ------- | ----------------------------------------------- | -| resolver\_ | address | Address of the current Business Logic Resolver. | -| configurationId\_ | bytes32 | Identifier of the active configuration. | -| version\_ | uint256 | Version number of the active configuration. | +| Name | Type | Description | +| ---------------------- | ------- | ----------------------------------------------- | +| resolver\_ | address | Address of the current Business Logic Resolver. | +| proxyVersion\_ | bytes8 | proxy version. | +| configurationId\_ | bytes32 | Identifier of the active configuration. | +| configurationVersion\_ | uint256 | Version number of the active configuration. | +| replacementEnabled\_ | bool | Whether replacement is enabled. | ### getFacet @@ -344,18 +346,33 @@ For the current BLR and configuration, update the used version. | ------------ | ------- | ------------------------------------------------------------ | | \_newVersion | uint256 | The new version number to set for the current configuration. | +### updateReplacementEnabled + +```solidity +function updateReplacementEnabled(bool _newReplacementEnabled) external nonpayable +``` + +For the current BLR update its configuration + +#### Parameters + +| Name | Type | Description | +| ----------------------- | ---- | ------------------------------------- | +| \_newReplacementEnabled | bool | The replacement enabled flag to set\* | + ### updateResolver ```solidity -function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion) external nonpayable +function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion, bool _newReplacementEnabled) external nonpayable ``` Replaces the Business Logic Resolver with a new one, setting configuration and version. #### Parameters -| Name | Type | Description | -| -------------------- | ------------------------------- | ------------------------------------------------------------- | -| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | -| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | -| \_newVersion | uint256 | The version number associated with the new configuration. | +| Name | Type | Description | +| ----------------------- | ------------------------------- | ------------------------------------------------------------- | +| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | +| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | +| \_newVersion | uint256 | The version number associated with the new configuration. | +| \_newReplacementEnabled | bool | The replacement enabled flag to set. | diff --git a/docs/ats/api/contracts/infrastructure/proxy/IDiamondCut.md b/docs/ats/api/contracts/infrastructure/proxy/IDiamondCut.md index dd2666f5d6..c8d39fea99 100644 --- a/docs/ats/api/contracts/infrastructure/proxy/IDiamondCut.md +++ b/docs/ats/api/contracts/infrastructure/proxy/IDiamondCut.md @@ -11,18 +11,20 @@ Interface for upgrading the Diamond proxy's Business Logic Resolver (BLR), c ### getConfigInfo ```solidity -function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_) +function getConfigInfo() external view returns (address resolver_, bytes8 proxyVersion_, bytes32 configurationId_, uint256 configurationVersion_, bool replacementEnabled_) ``` Returns the active resolver address, configuration identifier, and version. #### Returns -| Name | Type | Description | -| ----------------- | ------- | ----------------------------------------------- | -| resolver\_ | address | Address of the current Business Logic Resolver. | -| configurationId\_ | bytes32 | Identifier of the active configuration. | -| version\_ | uint256 | Version number of the active configuration. | +| Name | Type | Description | +| ---------------------- | ------- | ----------------------------------------------- | +| resolver\_ | address | Address of the current Business Logic Resolver. | +| proxyVersion\_ | bytes8 | proxy version. | +| configurationId\_ | bytes32 | Identifier of the active configuration. | +| configurationVersion\_ | uint256 | Version number of the active configuration. | +| replacementEnabled\_ | bool | Whether replacement is enabled. | ### getStaticFunctionSelectors @@ -95,18 +97,33 @@ For the current BLR and configuration, update the used version. | ------------ | ------- | ------------------------------------------------------------ | | \_newVersion | uint256 | The new version number to set for the current configuration. | +### updateReplacementEnabled + +```solidity +function updateReplacementEnabled(bool _newReplacementEnabled) external nonpayable +``` + +For the current BLR update its configuration + +#### Parameters + +| Name | Type | Description | +| ----------------------- | ---- | ------------------------------------- | +| \_newReplacementEnabled | bool | The replacement enabled flag to set\* | + ### updateResolver ```solidity -function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion) external nonpayable +function updateResolver(contract IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, uint256 _newVersion, bool _newReplacementEnabled) external nonpayable ``` Replaces the Business Logic Resolver with a new one, setting configuration and version. #### Parameters -| Name | Type | Description | -| -------------------- | ------------------------------- | ------------------------------------------------------------- | -| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | -| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | -| \_newVersion | uint256 | The version number associated with the new configuration. | +| Name | Type | Description | +| ----------------------- | ------------------------------- | ------------------------------------------------------------- | +| \_newResolver | contract IBusinessLogicResolver | The new BLR contract address to wire into the proxy. | +| \_newConfigurationId | bytes32 | The configuration identifier to activate on the new resolver. | +| \_newVersion | uint256 | The version number associated with the new configuration. | +| \_newReplacementEnabled | bool | The replacement enabled flag to set. | diff --git a/docs/ats/api/contracts/infrastructure/proxy/IResolverProxy.md b/docs/ats/api/contracts/infrastructure/proxy/IResolverProxy.md index 6eb393cceb..ff8af07626 100644 --- a/docs/ats/api/contracts/infrastructure/proxy/IResolverProxy.md +++ b/docs/ats/api/contracts/infrastructure/proxy/IResolverProxy.md @@ -21,3 +21,17 @@ Thrown when no function exists for function called. | Name | Type | Description | | ------------------ | ------ | ------------------------------------------------------------- | | \_functionSelector | bytes4 | The four-byte selector that could not be resolved to a facet. | + +### UnrecognizedResolverProxyConfigurationVersion + +```solidity +error UnrecognizedResolverProxyConfigurationVersion(uint256 _resolverProxyConfigurationVersion) +``` + +Thrown when the stored configuration carries an unrecognized version tag + +#### Parameters + +| Name | Type | Description | +| ----------------------------------- | ------- | ----------- | +| \_resolverProxyConfigurationVersion | uint256 | undefined | diff --git a/package-lock.json b/package-lock.json index 60f9c92886..9b18183fc5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15825,7 +15825,6 @@ "version": "2.2.1", "resolved": "https://registry.npmjs.org/@onchain-id/solidity/-/solidity-2.2.1.tgz", "integrity": "sha512-B54InT8yi89qlh9UVCARcfdQLVDP7Lef87B/Ww2Wn19oyEbPmlWho2EK1sgnrt/8Q0fGX/7y5rDnx3HPy28NTA==", - "dev": true, "license": "ISC" }, "node_modules/@openzeppelin/contracts": { @@ -20652,7 +20651,6 @@ "os": [ "darwin" ], - "peer": true, "engines": { "node": ">=10" } @@ -20669,7 +20667,6 @@ "os": [ "darwin" ], - "peer": true, "engines": { "node": ">=10" } @@ -20686,7 +20683,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20703,7 +20699,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20720,7 +20715,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20737,7 +20731,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20754,7 +20747,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20771,7 +20763,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20788,7 +20779,6 @@ "os": [ "linux" ], - "peer": true, "engines": { "node": ">=10" } @@ -20805,7 +20795,6 @@ "os": [ "win32" ], - "peer": true, "engines": { "node": ">=10" } @@ -20822,7 +20811,6 @@ "os": [ "win32" ], - "peer": true, "engines": { "node": ">=10" } @@ -20839,7 +20827,6 @@ "os": [ "win32" ], - "peer": true, "engines": { "node": ">=10" } @@ -62838,7 +62825,7 @@ }, "packages/ats/contracts": { "name": "@hashgraph/asset-tokenization-contracts", - "version": "8.0.0", + "version": "8.0.1", "license": "Apache-2.0", "dependencies": { "dotenv": "^16.0.3", @@ -63026,6 +63013,19 @@ "dev": true, "license": "MIT" }, + "packages/ats/sdk/node_modules/@hashgraph/asset-tokenization-contracts": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@hashgraph/asset-tokenization-contracts/-/asset-tokenization-contracts-8.0.0.tgz", + "integrity": "sha512-OGxFWfb0FTaQtRSqETDGBPdxakYt0L/L2A5OgVlBtBCqs/Pz74NTLpqzPw/QOnOnhWiLLo9wYCKNze7sz5B8iQ==", + "license": "Apache-2.0", + "dependencies": { + "@onchain-id/solidity": "^2.2.1", + "dotenv": "^16.0.3", + "ethers": "^6.15.0", + "tslib": "^2.8.1", + "zod": "^3.22.4" + } + }, "packages/ats/sdk/node_modules/@jest/schemas": { "version": "30.0.5", "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", diff --git a/packages/ats/contracts/.betterer.results b/packages/ats/contracts/.betterer.results index 7e7d946692..d367bf7b02 100644 --- a/packages/ats/contracts/.betterer.results +++ b/packages/ats/contracts/.betterer.results @@ -66,11 +66,11 @@ exports[`ats contracts solhint`] = { "contracts/facets/dividend/IDividendTypes.sol:2960222249": [ [58, 4, 1, "gas-struct-packing: GC: For [ DividendFor ] struct, packing seems inefficient. Try rearranging to achieve 32bytes slots", "177622"] ], - "contracts/factory/IFactory.sol:3326367667": [ - [115, 4, 1, "gas-struct-packing: GC: For [ EquityDetailsData ] struct, packing seems inefficient. Try rearranging to achieve 32bytes slots", "177622"] + "contracts/factory/IFactory.sol:647350752": [ + [105, 4, 1, "gas-struct-packing: GC: For [ EquityDetailsData ] struct, packing seems inefficient. Try rearranging to achieve 32bytes slots", "177622"] ], - "contracts/infrastructure/proxy/ResolverProxy.sol:849945896": [ - [54, 4, 1, "no-complex-fallback: Fallback function must be simple", "177603"] + "contracts/infrastructure/proxy/ResolverProxy.sol:3628079828": [ + [52, 4, 1, "no-complex-fallback: Fallback function must be simple", "177603"] ], "contracts/infrastructure/utils/DecimalsLib.sol:1687496794": [ [6, 4, 1, "no-unused-import: imported name POW10_0 is not used", "177653"], diff --git a/packages/ats/contracts/contracts/constants/values.sol b/packages/ats/contracts/contracts/constants/values.sol index 2752a8fcf3..9b704dc76c 100644 --- a/packages/ats/contracts/contracts/constants/values.sol +++ b/packages/ats/contracts/contracts/constants/values.sol @@ -113,3 +113,6 @@ uint256 constant POW10_15 = 1e15; uint256 constant POW10_16 = 1e16; uint256 constant POW10_17 = 1e17; uint256 constant POW10_18 = 1e18; + +bytes8 constant RESOLVER_PROXY_VERSION_V2 = 0x0000000000000002; +uint256 constant RESOLVER_PROXY_CONFIGURATION_MINIMUM_LENGTH = 128; diff --git a/packages/ats/contracts/contracts/domain/asset/ERC20PermitStorageWrapper.sol b/packages/ats/contracts/contracts/domain/asset/ERC20PermitStorageWrapper.sol index 4d263a04f3..62c5c27fd3 100644 --- a/packages/ats/contracts/contracts/domain/asset/ERC20PermitStorageWrapper.sol +++ b/packages/ats/contracts/contracts/domain/asset/ERC20PermitStorageWrapper.sol @@ -80,7 +80,7 @@ library ERC20PermitStorageWrapper { return _getDomainHash( ERC20StorageWrapper.getName(), - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); diff --git a/packages/ats/contracts/contracts/domain/core/ERC3643StorageWrapper.sol b/packages/ats/contracts/contracts/domain/core/ERC3643StorageWrapper.sol index 30df6f18ca..e1c19572ba 100644 --- a/packages/ats/contracts/contracts/domain/core/ERC3643StorageWrapper.sol +++ b/packages/ats/contracts/contracts/domain/core/ERC3643StorageWrapper.sol @@ -403,6 +403,8 @@ library ERC3643StorageWrapper { * @return versionJson_ JSON-encoded version descriptor. */ function version() internal view returns (string memory versionJson_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + return string( abi.encodePacked( @@ -412,10 +414,10 @@ library ERC3643StorageWrapper { Strings.toHexString(uint160(address(ResolverProxyStorageWrapper.getBusinessLogicResolver())), 20), '", ', '"Config ID": "', - Strings.toHexString(uint256(ResolverProxyStorageWrapper.getResolverProxyConfigurationId()), 32), + Strings.toHexString(uint256(configId), 32), '", ', '"Version": "', - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(versionId), '"', "}" // solhint-enable quotes diff --git a/packages/ats/contracts/contracts/domain/core/InitializerStorageWrapper.sol b/packages/ats/contracts/contracts/domain/core/InitializerStorageWrapper.sol index 7a742ef5db..1be1a45f5a 100644 --- a/packages/ats/contracts/contracts/domain/core/InitializerStorageWrapper.sol +++ b/packages/ats/contracts/contracts/domain/core/InitializerStorageWrapper.sol @@ -81,8 +81,7 @@ library InitializerStorageWrapper { internal returns (bool isOperational_, uint256 lastFacetIndex_, bytes32 configId_, uint256 versionId_) { - configId_ = ResolverProxyStorageWrapper.getResolverProxyConfigurationId(); - versionId_ = ResolverProxyStorageWrapper.getResolverProxyVersion(); + (configId_, versionId_) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); uint256 operationStatus = getOperationalStatus(configId_, versionId_); @@ -190,10 +189,10 @@ library InitializerStorageWrapper { * check to `isConfigVersionOperational`. Reverts with `IInitializer.AssetNotOperational`. */ function checkOperational() internal view { - isConfigVersionOperational( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion() - ); + bytes32 configId; + uint256 versionId; + (configId, versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + isConfigVersionOperational(configId, versionId); } /** @@ -313,10 +312,12 @@ library InitializerStorageWrapper { * @return version_ Current version of the facet within the active configuration. */ function currentFacetVersion(bytes32 _facetId) internal view returns (uint256 version_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + return ResolverProxyStorageWrapper.getBusinessLogicResolver().getFacetVersionByConfigurationIdVersionAndFacetId( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _facetId ); } diff --git a/packages/ats/contracts/contracts/domain/core/ProtectedPartitionsStorageWrapper.sol b/packages/ats/contracts/contracts/domain/core/ProtectedPartitionsStorageWrapper.sol index 1f82e710c3..163bb65a6f 100644 --- a/packages/ats/contracts/contracts/domain/core/ProtectedPartitionsStorageWrapper.sol +++ b/packages/ats/contracts/contracts/domain/core/ProtectedPartitionsStorageWrapper.sol @@ -157,7 +157,7 @@ library ProtectedPartitionsStorageWrapper { ), _protectionData.signature, _name, - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); @@ -205,7 +205,7 @@ library ProtectedPartitionsStorageWrapper { _getMessageHashRedeem(_partition, _from, _amount, _protectionData.deadline, _protectionData.nonce), _protectionData.signature, _name, - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); @@ -253,7 +253,7 @@ library ProtectedPartitionsStorageWrapper { _getMessageHashCreateHold(_partition, _from, _protectedHold), _signature, _name, - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); @@ -300,7 +300,7 @@ library ProtectedPartitionsStorageWrapper { _getMessageHashClearingCreateHold(_protectedClearingOperation, _hold), _signature, _name, - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); @@ -351,7 +351,7 @@ library ProtectedPartitionsStorageWrapper { _getMessageHashClearingTransfer(_protectedClearingOperation, _to, _amount), _signature, _name, - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); @@ -398,7 +398,7 @@ library ProtectedPartitionsStorageWrapper { _getMessageHashClearingRedeem(_protectedClearingOperation, _amount), _signature, _name, - Strings.toString(ResolverProxyStorageWrapper.getResolverProxyVersion()), + Strings.toString(ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion()), EvmAccessors.getChainId(), address(this) ); diff --git a/packages/ats/contracts/contracts/domain/core/ResolverProxyStorageWrapper.sol b/packages/ats/contracts/contracts/domain/core/ResolverProxyStorageWrapper.sol index 118112499d..c93d14e221 100644 --- a/packages/ats/contracts/contracts/domain/core/ResolverProxyStorageWrapper.sol +++ b/packages/ats/contracts/contracts/domain/core/ResolverProxyStorageWrapper.sol @@ -2,6 +2,9 @@ pragma solidity >=0.8.0 <0.9.0; import { IBusinessLogicResolver } from "../../infrastructure/diamond/IBusinessLogicResolver.sol"; +import { IResolverProxy } from "../../infrastructure/proxy/IResolverProxy.sol"; +import { RESOLVER_PROXY_VERSION_V2 } from "../../constants/values.sol"; +import { IDiamondCutManager } from "../../infrastructure/diamond/IDiamondCutManager.sol"; /// @custom:hash storage ResolverProxy bytes32 constant STORAGE_LOCATION_RESOLVER_PROXY = 0x688a1184cf65cae3790aef0eb6006209aa488bc22d1dd13eb263813b07a39300; @@ -17,11 +20,7 @@ struct ResolverProxyStorage { // ─── R1 Lifecycle (bool flags) ─────────────────────────── // ─── R2 Packed scalars (uint8, bytes3, address, enum) ──── IBusinessLogicResolver resolver; - // ─── R3 Single-slot scalars (uint256, bytes32, string) ─── - bytes32 resolverProxyConfigurationId; - uint256 version; - // ─── R4 Aggregates (mapping, array, EnumerableSet) ─────── - // ─── APPEND-ONLY ZONE BELOW ─── + bytes resolverProxyConfiguration; //IResolverProxy.ResolverProxyConfigurationGeneric resolverProxyConfiguration; } /** @@ -36,42 +35,33 @@ library ResolverProxyStorageWrapper { /** * @notice Initializes the resolver-proxy storage. * @param _resolver The `BusinessLogicResolver` instance. - * @param _resolverProxyConfigurationId The configuration identifier. - * @param _version The configuration version. + * @param _resolverProxyConfigurationV2 The V2 configuration struct. */ function initResolverProxyStorage( IBusinessLogicResolver _resolver, - bytes32 _resolverProxyConfigurationId, - uint256 _version + IResolverProxy.ResolverProxyConfigurationV2 memory _resolverProxyConfigurationV2 ) internal { - ResolverProxyStorage storage ds = _resolverProxyStorage(); - ds.resolver = _resolver; - ds.resolverProxyConfigurationId = _resolverProxyConfigurationId; - ds.version = _version; + setBusinessLogicResolver(_resolver); + setResolverProxyConfigurationV2(_resolverProxyConfigurationV2); } - /** - * @notice Updates the `BusinessLogicResolver` instance. - * @param _resolver The new resolver instance. - */ function setBusinessLogicResolver(IBusinessLogicResolver _resolver) internal { _resolverProxyStorage().resolver = _resolver; } /** - * @notice Updates the configuration identifier. - * @param _resolverProxyConfigurationId The new configuration identifier. + * @notice Stores a V2 configuration payload as a version-tagged envelope. + * @dev Serialises `_v2` into the generic envelope (`RESOLVER_PROXY_VERSION_V2` + ABI-encoded + * payload) and writes it to the single `bytes` slot consumed by `resolveResolverProxyCall`. + * @param _v2 The V2 configuration to persist. */ - function setResolverProxyConfigurationId(bytes32 _resolverProxyConfigurationId) internal { - _resolverProxyStorage().resolverProxyConfigurationId = _resolverProxyConfigurationId; - } - - /** - * @notice Updates the configuration version. - * @param _version The new configuration version. - */ - function setResolverProxyVersion(uint256 _version) internal { - _resolverProxyStorage().version = _version; + function setResolverProxyConfigurationV2(IResolverProxy.ResolverProxyConfigurationV2 memory _v2) internal { + _resolverProxyStorage().resolverProxyConfiguration = abi.encode( + IResolverProxy.ResolverProxyConfigurationGeneric({ + resolverProxyVersion: RESOLVER_PROXY_VERSION_V2, + content: abi.encode(_v2) + }) + ); } /** @@ -82,20 +72,93 @@ library ResolverProxyStorageWrapper { return _resolverProxyStorage().resolver; } + /** + * @notice Returns the proxy configuration. + * @return The proxy configuration. + */ + function getProxyConfiguration() internal view returns (bytes memory) { + return _resolverProxyStorage().resolverProxyConfiguration; + } + + /** + * @notice Returns the pinned resolver proxy version served by the proxy. + * @return The resolver proxy version. + */ + function getResolverProxyVersion() internal view returns (bytes8) { + return _decodeGeneric().resolverProxyVersion; + } + + /** + * @notice Returns the configuration identifier selecting the facet set served by the proxy. + * @return The configured `bytes32` identifier. + * @return The version `uint256` identifier. + */ + function getResolverProxyConfigurationIdAndVersion() internal view returns (bytes32, uint256) { + bytes8 resolverProxyVersion = getResolverProxyVersion(); + if (resolverProxyVersion == RESOLVER_PROXY_VERSION_V2) { + IResolverProxy.ResolverProxyConfigurationV2 + memory resolverProxyConfigurationV2 = getResolverProxyConfigurationV2(); + return (resolverProxyConfigurationV2.configurationId, resolverProxyConfigurationV2.configurationVersion); + } + revert IDiamondCutManager.UnrecognizedResolverProxyVersion(resolverProxyVersion); + } + /** * @notice Returns the configuration identifier selecting the facet set served by the proxy. * @return The configured `bytes32` identifier. */ function getResolverProxyConfigurationId() internal view returns (bytes32) { - return _resolverProxyStorage().resolverProxyConfigurationId; + bytes8 resolverProxyVersion = getResolverProxyVersion(); + if (resolverProxyVersion == RESOLVER_PROXY_VERSION_V2) return getResolverProxyConfigurationV2().configurationId; + revert IDiamondCutManager.UnrecognizedResolverProxyVersion(resolverProxyVersion); } /** * @notice Returns the pinned configuration version served by the proxy. - * @return The configuration version, zero when the proxy tracks the latest. + * @return The configuration version. + */ + function getResolverProxyConfigurationVersion() internal view returns (uint256) { + bytes8 resolverProxyVersion = getResolverProxyVersion(); + if (resolverProxyVersion == RESOLVER_PROXY_VERSION_V2) + return getResolverProxyConfigurationV2().configurationVersion; + revert IDiamondCutManager.UnrecognizedResolverProxyVersion(resolverProxyVersion); + } + + /** + * @notice Returns the replacement enabled flag served by the proxy. + * @return The replacement enabled flag. + */ + function getResolverProxyReplacementEnabled() internal view returns (bool) { + bytes8 resolverProxyVersion = getResolverProxyVersion(); + if (resolverProxyVersion == RESOLVER_PROXY_VERSION_V2) + return getResolverProxyConfigurationV2().replacementEnabled; + revert IDiamondCutManager.UnrecognizedResolverProxyVersion(resolverProxyVersion); + } + + /** + * @notice Returns the full V2 configuration payload served by the proxy. + * @return The decoded V2 configuration. + */ + function getResolverProxyConfigurationV2() + internal + view + returns (IResolverProxy.ResolverProxyConfigurationV2 memory) + { + IResolverProxy.ResolverProxyConfigurationGeneric memory generic = _decodeGeneric(); + return abi.decode(generic.content, (IResolverProxy.ResolverProxyConfigurationV2)); + } + + /** + * @notice Decodes the version-tagged configuration envelope held in storage. + * @dev The outer `ResolverProxyConfigurationGeneric` shape is fixed across versions, so this + * decode succeeds regardless of which payload version `content` carries. + * @return generic The decoded generic configuration. */ - function getResolverProxyVersion() internal view returns (uint256) { - return _resolverProxyStorage().version; + function _decodeGeneric() private view returns (IResolverProxy.ResolverProxyConfigurationGeneric memory generic) { + generic = abi.decode( + _resolverProxyStorage().resolverProxyConfiguration, + (IResolverProxy.ResolverProxyConfigurationGeneric) + ); } /** diff --git a/packages/ats/contracts/contracts/factory/Factory.sol b/packages/ats/contracts/contracts/factory/Factory.sol index 3dece6e8e6..659b1cadf4 100644 --- a/packages/ats/contracts/contracts/factory/Factory.sol +++ b/packages/ats/contracts/contracts/factory/Factory.sol @@ -198,21 +198,26 @@ abstract contract Factory is IFactory { * @dev The resolver must be non-zero and `_rbacs` must include at least one non-zero * `DEFAULT_ADMIN_ROLE` member. Emits `ProxyDeployed`. * @param _resolver Business logic resolver used by the proxy. - * @param _configKey Resolver configuration key selecting the facet set. - * @param _version Resolver configuration version to activate. + * @param _resolverProxyConfigurationV2 Resolver configuration data for the proxy. * @param _rbacs Initial RBAC assignments applied by the proxy constructor. * @param _data Additional data for the proxy deployment. * @return proxyAddress_ Address of the deployed resolver proxy. */ function deployProxy( IBusinessLogicResolver _resolver, - bytes32 _configKey, - uint256 _version, + IResolverProxy.ResolverProxyConfigurationV2 calldata _resolverProxyConfigurationV2, IResolverProxy.Rbac[] calldata _rbacs, bytes calldata _data ) external onlyValidResolver(_resolver) onlyValidAdmins(_rbacs) returns (address proxyAddress_) { - proxyAddress_ = address(new ResolverProxy(_resolver, _configKey, _version, _rbacs)); - emit ProxyDeployed(proxyAddress_, _resolver, _configKey, _version, _rbacs, _data); + proxyAddress_ = address(new ResolverProxy(_resolver, _resolverProxyConfigurationV2, _rbacs)); + emit ProxyDeployed( + proxyAddress_, + _resolver, + _resolverProxyConfigurationV2.configurationId, + _resolverProxyConfigurationV2.configurationVersion, + _rbacs, + _data + ); } /** @@ -439,8 +444,7 @@ abstract contract Factory is IFactory { extendedRbacs[rbacsLen].members[0] = address(this); ResolverProxy proxy = new ResolverProxy( _securityData.resolver, - _securityData.resolverProxyConfiguration.key, - _securityData.resolverProxyConfiguration.version, + _securityData.resolverProxyConfigurationV2, extendedRbacs ); securityAddress_ = address(proxy); diff --git a/packages/ats/contracts/contracts/factory/IFactory.sol b/packages/ats/contracts/contracts/factory/IFactory.sol index fde9a7e6cf..6259a7958a 100644 --- a/packages/ats/contracts/contracts/factory/IFactory.sol +++ b/packages/ats/contracts/contracts/factory/IFactory.sol @@ -47,16 +47,6 @@ interface IFactory { COMMON } - /** - * @notice Identifies the business-logic resolver version to wire into a new proxy. - * @param key Resolver key that maps to the registered BusinessLogicResolver address. - * @param version Configuration version to load from the resolver. - */ - struct ResolverProxyConfiguration { - bytes32 key; - uint256 version; - } - /** * @notice Core configuration shared across all security types. * @dev Passed verbatim to the proxy initialiser; all addresses must be non-zero where @@ -82,7 +72,7 @@ interface IFactory { struct SecurityData { IBusinessLogicResolver resolver; uint256 maxSupply; - ResolverProxyConfiguration resolverProxyConfiguration; + IResolverProxy.ResolverProxyConfigurationV2 resolverProxyConfigurationV2; ICore.ERC20MetadataInfo erc20MetadataInfo; IResolverProxy.Rbac[] rbacs; address[] externalPauses; @@ -261,17 +251,15 @@ interface IFactory { /** * @notice Deploys a new resolver proxy and initialises its RBAC. * @param _resolver Business-logic resolver to attach. - * @param _configKey Configuration identifier for the proxy. - * @param _version Initial configuration version. + * @param _resolverProxyConfigurationV2 Resolver configuration data for the proxy. * @param _rbacs Role-based access control entries to seed. * @param _data Additional data for the proxy deployment. * @return proxyAddress_ Address of the deployed proxy. */ function deployProxy( IBusinessLogicResolver _resolver, - bytes32 _configKey, - uint256 _version, - IResolverProxy.Rbac[] calldata _rbacs, + IResolverProxy.ResolverProxyConfigurationV2 memory _resolverProxyConfigurationV2, + IResolverProxy.Rbac[] memory _rbacs, bytes calldata _data ) external returns (address proxyAddress_); diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolver.sol b/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolver.sol index 30d4b8e02c..e2ff781263 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolver.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolver.sol @@ -66,6 +66,37 @@ contract BusinessLogicResolver is IBusinessLogicResolver, DiamondCutManager { _removeSelectorsFromBlacklist(_configurationId, _selectors); } + /// @inheritdoc IBusinessLogicResolver + function updateReplacementAddress( + address _replacedAddress, + address _replacementAddress + ) + external + override + validateAddressNotZero(_replacedAddress) + validateAddressNotZero(_replacementAddress) + onlyNotReplacement(_replacedAddress) + onlyNotReplaced(_replacementAddress) + onlyRole(DEFAULT_ADMIN_ROLE) + onlyUnpaused + { + _updateReplacementAddress(_replacedAddress, _replacementAddress); + emit ReplacementAddressUpdated(_replacedAddress, _replacementAddress); + } + + /// @inheritdoc IBusinessLogicResolver + function removeReplacementAddress( + address _replacedAddress + ) external override onlyRole(DEFAULT_ADMIN_ROLE) onlyUnpaused { + address replacementAddressRemoved = _removeReplacementAddress(_replacedAddress); + emit ReplacementAddressRemoved(_replacedAddress, replacementAddressRemoved); + } + + /// @inheritdoc IBusinessLogicResolver + function getReplacementAddress(address _replacedAddress) external view returns (address replacementAddress_) { + replacementAddress_ = _getReplacementAddress(_replacedAddress); + } + /// @inheritdoc IBusinessLogicResolver function getVersionStatus( bytes32 _businessLogicKey, diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.sol b/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.sol index b8744d5bee..93cd8faa5d 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/BusinessLogicResolverWrapper.sol @@ -47,6 +47,8 @@ struct BusinessLogicResolverDataStorage { mapping(bytes32 facetIdAndVersion => IBusinessLogicResolver.VersionStatus status) statusByFacetIdAndVersion; mapping(bytes32 => EnumerableSetBytes4.Bytes4Set) selectorBlacklist; // ─── APPEND-ONLY ZONE BELOW ─── + mapping(address => address) replacementAddressMap; + mapping(address => uint256) replacementAddressCount; } /** @@ -81,6 +83,26 @@ abstract contract BusinessLogicResolverWrapper is IBusinessLogicResolver { _; } + /** + * @notice Restricts execution to addresses that have not themselves been replaced. + * @dev Reverts via `_checkNotReplaced` when `_address` already maps to a replacement. + * @param _address Address whose non-replaced status is validated. + */ + modifier onlyNotReplaced(address _address) { + _checkNotReplaced(_address); + _; + } + + /** + * @notice Restricts execution to addresses that are not registered as a replacement. + * @dev Reverts via `_checkNotReplacement` when `_address` is in use as a replacement. + * @param _address Address whose non-replacement status is validated. + */ + modifier onlyNotReplacement(address _address) { + _checkNotReplacement(_address); + _; + } + /** * @notice Registers new business logic versions and activates unseen business logic keys. * @dev Increments the latest version per key, validates the implementation static resolver @@ -186,6 +208,34 @@ abstract contract BusinessLogicResolverWrapper is IBusinessLogicResolver { } } + /** + * @notice Registers `_newAddress` as the replacement for `_oldAddress`. + * @dev Maps `_oldAddress` to `_newAddress` and increments the replacement reference count for + * `_newAddress`. + * @param _oldAddress Address being replaced. + * @param _newAddress Address that supersedes `_oldAddress`. + */ + function _updateReplacementAddress(address _oldAddress, address _newAddress) internal { + BusinessLogicResolverDataStorage storage businessLogicResolverDataStorage = _businessLogicResolverStorage(); + businessLogicResolverDataStorage.replacementAddressMap[_oldAddress] = _newAddress; + ++businessLogicResolverDataStorage.replacementAddressCount[_newAddress]; + } + + /** + * @notice Clears the replacement registered for `_oldAddress`. + * @dev Resets the mapping to the zero address and decrements the replacement reference count for + * the removed address. No-ops and returns the zero address when no replacement exists. + * @param _oldAddress Address whose replacement is removed. + * @return newAddressRemoved_ The replacement address that was cleared, or the zero address if none. + */ + function _removeReplacementAddress(address _oldAddress) internal returns (address newAddressRemoved_) { + BusinessLogicResolverDataStorage storage businessLogicResolverDataStorage = _businessLogicResolverStorage(); + newAddressRemoved_ = businessLogicResolverDataStorage.replacementAddressMap[_oldAddress]; + if (newAddressRemoved_ == address(0)) return newAddressRemoved_; + businessLogicResolverDataStorage.replacementAddressMap[_oldAddress] = address(0); + --businessLogicResolverDataStorage.replacementAddressCount[newAddressRemoved_]; + } + /** * @notice Returns the status stored for a business logic version. * @dev Returns `NONE` for keys or versions without an explicit status entry. @@ -343,6 +393,47 @@ abstract contract BusinessLogicResolverWrapper is IBusinessLogicResolver { return _businessLogicResolverStorage().initialized; } + /** + * @notice Returns the replacement registered for an address. + * @dev Returns the zero address when `_address` has not been replaced. + * @param _address Address to query. + * @return The replacement address mapped to `_address`, or the zero address if none. + */ + function _getReplacementAddress(address _address) internal view returns (address) { + return _businessLogicResolverStorage().replacementAddressMap[_address]; + } + + /** + * @notice Returns how many times an address is registered as a replacement. + * @dev A non-zero count means `_address` is currently in use as a replacement for one or more + * addresses. + * @param _address Address to query. + * @return The replacement reference count for `_address`. + */ + function _getReplacementAddressCount(address _address) internal view returns (uint256) { + return _businessLogicResolverStorage().replacementAddressCount[_address]; + } + + /** + * @notice Reverts when a replacement address is itself been replaced by another one. + * @param _address The replacement address been replaced. + */ + function _checkNotReplaced(address _address) internal view { + if (_getReplacementAddress(_address) != address(0)) { + revert InvalidReplacementAddress(_address); + } + } + + /** + * @notice Reverts when a replaced address is itself replacing other addresses. + * @param _address The replaced address been used as replacement. + */ + function _checkNotReplacement(address _address) internal view { + if (_getReplacementAddressCount(_address) > 0) { + revert InvalidReplacedAddress(_address); + } + } + /** * @notice Validates that a business logic version exists. * @dev Reverts when `_version` is zero or greater than the key's latest registered version. diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCut.sol b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCut.sol index 5038a982ca..1676acfb45 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCut.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCut.sol @@ -8,6 +8,7 @@ import { DEFAULT_ADMIN_ROLE } from "../../constants/roles.sol"; import { AccessControlStorageWrapper } from "../../domain/core/AccessControlStorageWrapper.sol"; import { ResolverProxyStorageWrapper } from "../../domain/core/ResolverProxyStorageWrapper.sol"; import { EvmAccessors } from "../../infrastructure/utils/EvmAccessors.sol"; +import { IResolverProxy } from "../proxy/IResolverProxy.sol"; /** * @title Diamond Cut @@ -32,12 +33,22 @@ abstract contract DiamondCut is IDiamondCut, ResolverProxyUnstructured { /// @inheritdoc IDiamondCut /// @dev Requires `DEFAULT_ADMIN_ROLE` and preserves the active configuration identifier and /// resolver while updating only the pinned configuration version. - function updateConfigVersion(uint256 _newVersion) external override onlyRole(DEFAULT_ADMIN_ROLE) { - ResolverProxyStorageWrapper.getBusinessLogicResolver().checkResolverProxyConfigurationRegistered( + function updateConfigVersion( + uint256 _newVersion + ) + external + override + onlyRole(DEFAULT_ADMIN_ROLE) + onlyRegisteredResolverProxyConfiguration( + ResolverProxyStorageWrapper.getBusinessLogicResolver(), ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), _newVersion - ); - _updateVersion(_newVersion); + ) + { + IResolverProxy.ResolverProxyConfigurationV2 memory v2 = ResolverProxyStorageWrapper + .getResolverProxyConfigurationV2(); + v2.configurationVersion = _newVersion; + ResolverProxyStorageWrapper.setResolverProxyConfigurationV2(v2); } /// @inheritdoc IDiamondCut @@ -46,13 +57,29 @@ abstract contract DiamondCut is IDiamondCut, ResolverProxyUnstructured { function updateConfig( bytes32 _newConfigurationId, uint256 _newVersion - ) external override onlyRole(DEFAULT_ADMIN_ROLE) { - ResolverProxyStorageWrapper.getBusinessLogicResolver().checkResolverProxyConfigurationRegistered( + ) + external + override + onlyRole(DEFAULT_ADMIN_ROLE) + onlyRegisteredResolverProxyConfiguration( + ResolverProxyStorageWrapper.getBusinessLogicResolver(), _newConfigurationId, _newVersion - ); - _updateConfigId(_newConfigurationId); - _updateVersion(_newVersion); + ) + { + IResolverProxy.ResolverProxyConfigurationV2 memory v2 = ResolverProxyStorageWrapper + .getResolverProxyConfigurationV2(); + v2.configurationId = _newConfigurationId; + v2.configurationVersion = _newVersion; + ResolverProxyStorageWrapper.setResolverProxyConfigurationV2(v2); + } + + /// @inheritdoc IDiamondCut + function updateReplacementEnabled(bool _newReplacementEnabled) external override onlyRole(DEFAULT_ADMIN_ROLE) { + IResolverProxy.ResolverProxyConfigurationV2 memory v2 = ResolverProxyStorageWrapper + .getResolverProxyConfigurationV2(); + v2.replacementEnabled = _newReplacementEnabled; + ResolverProxyStorageWrapper.setResolverProxyConfigurationV2(v2); } /// @inheritdoc IDiamondCut @@ -61,25 +88,42 @@ abstract contract DiamondCut is IDiamondCut, ResolverProxyUnstructured { function updateResolver( IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, - uint256 _newVersion - ) external override onlyRole(DEFAULT_ADMIN_ROLE) { - _newResolver.checkResolverProxyConfigurationRegistered(_newConfigurationId, _newVersion); - _updateResolver(_newResolver); - _updateConfigId(_newConfigurationId); - _updateVersion(_newVersion); + uint256 _newVersion, + bool _newReplacementEnabled + ) + external + override + onlyRole(DEFAULT_ADMIN_ROLE) + onlyRegisteredResolverProxyConfiguration(_newResolver, _newConfigurationId, _newVersion) + { + ResolverProxyStorageWrapper.setBusinessLogicResolver(_newResolver); + ResolverProxyStorageWrapper.setResolverProxyConfigurationV2( + IResolverProxy.ResolverProxyConfigurationV2({ + configurationId: _newConfigurationId, + configurationVersion: _newVersion, + replacementEnabled: _newReplacementEnabled + }) + ); } /// @inheritdoc IDiamondCut function getConfigInfo() external view - override - returns (address resolver_, bytes32 configurationId_, uint256 version_) + returns ( + address resolver_, + bytes8 proxyVersion_, + bytes32 configurationId_, + uint256 configurationVersion_, + bool replacementEnabled_ + ) { return ( address(ResolverProxyStorageWrapper.getBusinessLogicResolver()), + ResolverProxyStorageWrapper.getResolverProxyVersion(), ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion() + ResolverProxyStorageWrapper.getResolverProxyConfigurationVersion(), + ResolverProxyStorageWrapper.getResolverProxyReplacementEnabled() ); } } diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManager.sol b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManager.sol index ea85c1745d..8495710534 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManager.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManager.sol @@ -99,7 +99,7 @@ abstract contract DiamondCutManager is AccessControl, Pause, DiamondCutManagerWr onlyRole(ROLE_CREATE_CONFIGURATION) { uint256 version = _cancelBatchConfiguration(_configurationId); - emit DiamondBatchConfigurationCanceled(_configurationId, version); + emit DiamondBatchConfigurationCancelled(_configurationId, version); } /// @inheritdoc IDiamondCutManager @@ -108,7 +108,15 @@ abstract contract DiamondCutManager is AccessControl, Pause, DiamondCutManagerWr uint256 _version, bytes4 _selector ) external view override onlyValidConfigurationVersion(_configurationId, _version) returns (address facetAddress_) { - facetAddress_ = _resolveResolverProxyCall(_configurationId, _version, _selector); + facetAddress_ = _resolveResolverProxyCallV2(_configurationId, _version, false, _selector); + } + + /// @inheritdoc IDiamondCutManager + function resolveResolverProxyCall( + bytes calldata _resolverProxyConfiguration, + bytes4 _selector + ) external view override returns (address facetAddress_) { + facetAddress_ = _resolveResolverProxyCall(_resolverProxyConfiguration, _selector); } /// @inheritdoc IDiamondCutManager diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManagerWrapper.sol b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManagerWrapper.sol index 4666b34c06..64807aaab9 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManagerWrapper.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondCutManagerWrapper.sol @@ -8,6 +8,8 @@ import { IStaticFunctionSelectors } from "../proxy/IStaticFunctionSelectors.sol" import { IDiamondLoupe } from "../proxy/IDiamondLoupe.sol"; import { Ownership } from "./Ownership.sol"; import { EvmAccessors } from "../utils/EvmAccessors.sol"; +import { IResolverProxy } from "../../infrastructure/proxy/IResolverProxy.sol"; +import { RESOLVER_PROXY_VERSION_V2, RESOLVER_PROXY_CONFIGURATION_MINIMUM_LENGTH } from "../../constants/values.sol"; /** * @dev Must remain stable across upgrades to preserve the diamond storage layout. @@ -257,19 +259,66 @@ abstract contract DiamondCutManagerWrapper is IDiamondCutManager, Ownership, Bus /** * @notice Resolves the facet address that handles a selector for a configuration version. - * @param _dcms Diamond cut manager storage reference. * @param _configurationId Identifier of the configuration to query. * @param _version Configuration version to query. + * @param _replacementEnabled Flag indicating whether selector replacement is enabled for the resolver proxy. * @param _selector Function selector to resolve. * @return facetAddress_ Facet address registered for the selector, or zero if absent. */ - function _resolveResolverProxyCall( - DiamondCutManagerStorage storage _dcms, + function _resolveResolverProxyCallV2( bytes32 _configurationId, uint256 _version, + bool _replacementEnabled, bytes4 _selector ) internal view returns (address facetAddress_) { - facetAddress_ = _dcms.facetAddress[_buildHashSelector(_configurationId, _version, _selector)]; + facetAddress_ = _diamondCutManagerStorage().facetAddress[ + _buildHashSelector(_configurationId, _version, _selector) + ]; + if (_replacementEnabled) { + address replacementAddress = _getReplacementAddress(facetAddress_); + if (replacementAddress != address(0)) { + facetAddress_ = replacementAddress; + } + } + } + + /** + * @notice Generic method that resolves the facet address that handles a selector for a configuration version. + * @param _resolverProxyConfiguration encoded proxy configuration. + * @param _selector Function selector to resolve. + * @return facetAddress_ Facet address registered for the selector, or zero if absent. + */ + function _resolveResolverProxyCall( + bytes calldata _resolverProxyConfiguration, + bytes4 _selector + ) internal view returns (address facetAddress_) { + if ( + _resolverProxyConfiguration.length < RESOLVER_PROXY_CONFIGURATION_MINIMUM_LENGTH || + _resolverProxyConfiguration.length % 32 != 0 + ) revert InvalidResolverProxyConfiguration(_resolverProxyConfiguration); + + IResolverProxy.ResolverProxyConfigurationGeneric memory configuration = abi.decode( + _resolverProxyConfiguration, + (IResolverProxy.ResolverProxyConfigurationGeneric) + ); + + if (configuration.resolverProxyVersion == RESOLVER_PROXY_VERSION_V2) { + IResolverProxy.ResolverProxyConfigurationV2 memory configurationV2 = abi.decode( + configuration.content, + (IResolverProxy.ResolverProxyConfigurationV2) + ); + + _checkExplicitVersion(configurationV2.configurationId, configurationV2.configurationVersion); + + facetAddress_ = _resolveResolverProxyCallV2( + configurationV2.configurationId, + configurationV2.configurationVersion, + configurationV2.replacementEnabled, + _selector + ); + return facetAddress_; + } + revert UnrecognizedResolverProxyVersion(configuration.resolverProxyVersion); } /** @@ -324,24 +373,6 @@ abstract contract DiamondCutManagerWrapper is IDiamondCutManager, Ownership, Bus _version > _dcms.latestVersion[_configurationId]; } - /** - * @notice Reverts unless a resolver proxy configuration version is registered. - * @dev Version zero is not explicitly rejected here unless the configuration is inactive; - * callers requiring explicit versions should use `onlyValidConfigurationVersion`. - * @param _dcms Diamond cut manager storage reference. - * @param _configurationId Identifier of the configuration to validate. - * @param _version Version to validate against the latest active version. - */ - function _checkResolverProxyConfigurationRegistered( - DiamondCutManagerStorage storage _dcms, - bytes32 _configurationId, - uint256 _version - ) internal view { - if (!_dcms.activeConfigurations[_configurationId] || _version > _dcms.latestVersion[_configurationId]) { - revert ResolverProxyConfigurationNoRegistered(_configurationId, _version); - } - } - /** * @notice Returns active configuration identifiers using pagination. * @param _dcms Diamond cut manager storage reference. diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondFacet.sol b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondFacet.sol index c993677f61..345c015964 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/DiamondFacet.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/DiamondFacet.sol @@ -27,12 +27,13 @@ contract DiamondFacet is IDiamond, DiamondBase { /// @inheritdoc IStaticFunctionSelectors /// @dev The selector count must remain aligned with the number of assigned selectors. function getStaticFunctionSelectors() external pure returns (bytes4[] memory staticFunctionSelectors_) { - uint256 selectorsIndex = 19; + uint256 selectorsIndex = 20; staticFunctionSelectors_ = new bytes4[](selectorsIndex); unchecked { staticFunctionSelectors_[--selectorsIndex] = this.initializeDiamondCut.selector; staticFunctionSelectors_[--selectorsIndex] = this.updateConfigVersion.selector; staticFunctionSelectors_[--selectorsIndex] = this.updateConfig.selector; + staticFunctionSelectors_[--selectorsIndex] = this.updateReplacementEnabled.selector; staticFunctionSelectors_[--selectorsIndex] = this.updateResolver.selector; staticFunctionSelectors_[--selectorsIndex] = this.getConfigInfo.selector; staticFunctionSelectors_[--selectorsIndex] = this.getFacets.selector; diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/IBusinessLogicResolver.sol b/packages/ats/contracts/contracts/infrastructure/diamond/IBusinessLogicResolver.sol index 377b81a9ed..9eb8a3e316 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/IBusinessLogicResolver.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/IBusinessLogicResolver.sol @@ -45,6 +45,16 @@ interface IBusinessLogicResolver is IDiamondCutManager { /// @param newLatestVersions new latest version per registered key, in the same order as `businessLogics`. event BusinessLogicsRegistered(BusinessLogicRegistryData[] businessLogics, uint256[] newLatestVersions); + /// @notice Event emitted when an old address is replaced with a new one + /// @param replacedAddress old address been replaced. + /// @param replacementAddress new address replacing the old one. + event ReplacementAddressUpdated(address indexed replacedAddress, address indexed replacementAddress); + + /// @notice Event emitted when a replacement address is removed + /// @param replacedAddress address for which the replacement is being removed. + /// @param replacementAddressRemoved removed replacement address. + event ReplacementAddressRemoved(address indexed replacedAddress, address indexed replacementAddressRemoved); + /// @notice Thrown when the requested version has never been registered for any business logic key. /// @param version The version number that does not exist in the registry. error BusinessLogicVersionDoesNotExist(uint256 version); @@ -62,6 +72,18 @@ interface IBusinessLogicResolver is IDiamondCutManager { /// @notice Thrown when a registration attempt uses the zero bytes32 value as the business logic key. error ZeroKeyNotValidForBusinessLogic(); + /** + * @notice Thrown when a replacement address is already been replaced. + * @param replacementAddress Replacement address that is already been replaced and thus cannot replaced another one. + */ + error InvalidReplacementAddress(address replacementAddress); + + /** + * @notice Thrown when a replaced address is already been used as replacement of other addresses. + * @param replacedAddress Replaced address. + */ + error InvalidReplacedAddress(address replacedAddress); + /** * @notice Initialises the Business Logic Resolver storage. Must be called once before any * registration operations; subsequent calls revert. @@ -91,6 +113,26 @@ interface IBusinessLogicResolver is IDiamondCutManager { */ function removeSelectorsFromBlacklist(bytes32 _configurationId, bytes4[] calldata _selectors) external; + /** + * @notice Updates the replacement address for a given address + * @param _oldAddress the address to be replaced + * @param _newAddress the new address to replace it with + */ + function updateReplacementAddress(address _oldAddress, address _newAddress) external; + + /** + * @notice Removes the replacement address for a given address + * @param _oldAddress the address for which to remove the replacement + */ + function removeReplacementAddress(address _oldAddress) external; + + /** + * @notice Returns the replacement address for a given address, or address(0) if none exists + * @param _oldAddress the address whose replacement is queried + * @return replacementAddress_ the replacement address, or address(0) if none exists + */ + function getReplacementAddress(address _oldAddress) external view returns (address replacementAddress_); + /** * @notice Returns the current status of a given version for a business logic key. * @param _businessLogicKey The bytes32 key identifying the business logic to query. diff --git a/packages/ats/contracts/contracts/infrastructure/diamond/IDiamondCutManager.sol b/packages/ats/contracts/contracts/infrastructure/diamond/IDiamondCutManager.sol index 5911969bf5..32ef6a09d1 100644 --- a/packages/ats/contracts/contracts/infrastructure/diamond/IDiamondCutManager.sol +++ b/packages/ats/contracts/contracts/infrastructure/diamond/IDiamondCutManager.sol @@ -70,7 +70,7 @@ interface IDiamondCutManager { * @param configurationId Configuration key whose pending batch was cancelled. * @param version Version number that was being assembled and is now dropped. */ - event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version); + event DiamondBatchConfigurationCancelled(bytes32 indexed configurationId, uint256 indexed version); /// @notice Thrown when `bytes32(0)` is supplied as a configuration id, which is reserved. error DefaultValueForConfigurationIdNotPermitted(); @@ -137,6 +137,18 @@ interface IDiamondCutManager { */ error SelectorAlreadyRegistered(bytes32 configurationId, uint256 version, bytes32 facetId, bytes4 selector); + /** + * @notice Thrown when the provided encoded proxy configuration does not respect the standard. + * @param _resolverProxyConfiguration wrong encoded proxy configuration. + */ + error InvalidResolverProxyConfiguration(bytes _resolverProxyConfiguration); + + /** + * @notice Thrown when the provided proxy version does not match any BLR compatible standard. + * @param _resolverProxyVersion proxy version that is not compatible with the BLR. + */ + error UnrecognizedResolverProxyVersion(bytes8 _resolverProxyVersion); + /** * @notice Registers a new configuration atomically, pinning each facet at the supplied * version. @@ -179,7 +191,7 @@ interface IDiamondCutManager { /** * @notice Discards an in-progress batch configuration, dropping every facet appended so * far for the pending version. - * @dev Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has + * @dev Emits {DiamondBatchConfigurationCancelled}. Has no effect once the version has * been finalised via a `_isLastBatch = true` call. * @param _configurationId Configuration key whose pending batch should be cancelled. */ @@ -214,6 +226,21 @@ interface IDiamondCutManager { bytes4 _selector ) external view returns (address facetAddress_); + /** + * @notice Resolves the facet address that implements a selector for a given + * configuration and version. + * @dev Used by resolver proxies during dispatch. Returns `address(0)` when no facet + * claims the selector. + * @param _resolverProxyConfiguration Resolver proxy full configuration. + * @param _selector Function selector being dispatched. + * @return facetAddress_ Address of the facet that owns `_selector`, or `address(0)` if + * the selector is not registered for the given configuration/version. + */ + function resolveResolverProxyCall( + bytes calldata _resolverProxyConfiguration, + bytes4 _selector + ) external view returns (address facetAddress_); + /** * @notice Reports whether an interface id is advertised by any facet inside the given * configuration and version. diff --git a/packages/ats/contracts/contracts/infrastructure/proxy/IDiamondCut.sol b/packages/ats/contracts/contracts/infrastructure/proxy/IDiamondCut.sol index cc740cf344..a6d3f4069f 100644 --- a/packages/ats/contracts/contracts/infrastructure/proxy/IDiamondCut.sol +++ b/packages/ats/contracts/contracts/infrastructure/proxy/IDiamondCut.sol @@ -22,23 +22,42 @@ interface IDiamondCut is IStaticFunctionSelectors { */ function updateConfig(bytes32 _newConfigurationId, uint256 _newVersion) external; + /** + * @notice For the current BLR update its configuration + * @param _newReplacementEnabled The replacement enabled flag to set + **/ + function updateReplacementEnabled(bool _newReplacementEnabled) external; + /** * @notice Replaces the Business Logic Resolver with a new one, setting configuration and version. * @param _newResolver The new BLR contract address to wire into the proxy. * @param _newConfigurationId The configuration identifier to activate on the new resolver. * @param _newVersion The version number associated with the new configuration. + * @param _newReplacementEnabled The replacement enabled flag to set. */ function updateResolver( IBusinessLogicResolver _newResolver, bytes32 _newConfigurationId, - uint256 _newVersion + uint256 _newVersion, + bool _newReplacementEnabled ) external; /** * @notice Returns the active resolver address, configuration identifier, and version. * @return resolver_ Address of the current Business Logic Resolver. + * @return proxyVersion_ proxy version. * @return configurationId_ Identifier of the active configuration. - * @return version_ Version number of the active configuration. + * @return configurationVersion_ Version number of the active configuration. + * @return replacementEnabled_ Whether replacement is enabled. */ - function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_); + function getConfigInfo() + external + view + returns ( + address resolver_, + bytes8 proxyVersion_, + bytes32 configurationId_, + uint256 configurationVersion_, + bool replacementEnabled_ + ); } diff --git a/packages/ats/contracts/contracts/infrastructure/proxy/IResolverProxy.sol b/packages/ats/contracts/contracts/infrastructure/proxy/IResolverProxy.sol index fe17a4f044..1261c88983 100644 --- a/packages/ats/contracts/contracts/infrastructure/proxy/IResolverProxy.sol +++ b/packages/ats/contracts/contracts/infrastructure/proxy/IResolverProxy.sol @@ -8,6 +8,26 @@ pragma solidity >=0.8.0 <0.9.0; * and the error thrown when an unknown function selector is called. */ interface IResolverProxy { + /// @notice Version-tagged envelope wrapping the proxy's stored configuration payload. + /// @dev The outer shape is fixed across versions: `resolverProxyVersion` selects how `content` + /// is decoded, allowing the configuration layout to evolve without breaking the storage slot. + /// @param resolverProxyVersion The eight-byte version tag identifying the payload schema (e.g. V2). + /// @param content The ABI-encoded version-specific configuration (e.g. `ResolverProxyConfigurationV2`). + struct ResolverProxyConfigurationGeneric { + bytes8 resolverProxyVersion; + bytes content; + } + + /// @notice Version 2 configuration selecting the facet selectors served by the proxy. + /// @param configurationId The identifier of the configuration registered in the `BusinessLogicResolver`. + /// @param configurationVersion The pinned version of that configuration the proxy resolves against. + /// @param replacementEnabled Whether selector replacement is permitted for this configuration. + struct ResolverProxyConfigurationV2 { + bytes32 configurationId; + uint256 configurationVersion; + bool replacementEnabled; + } + /// @notice Binds an access-control role to the set of addresses that hold it at construction time. /// @param role The bytes32 role identifier (e.g. DEFAULT_ADMIN_ROLE). /// @param members Addresses granted the role when the proxy is deployed. @@ -19,4 +39,7 @@ interface IResolverProxy { /// @notice Thrown when no function exists for function called. /// @param _functionSelector The four-byte selector that could not be resolved to a facet. error FunctionNotFound(bytes4 _functionSelector); + + /// @notice Thrown when the stored configuration carries an unrecognized version tag + error UnrecognizedResolverProxyConfigurationVersion(uint256 _resolverProxyConfigurationVersion); } diff --git a/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxy.sol b/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxy.sol index 7c2815df8b..55e7f57ba4 100644 --- a/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxy.sol +++ b/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxy.sol @@ -26,17 +26,15 @@ contract ResolverProxy is ResolverProxyUnstructured { * configuration data and assigning RBAC roles. The constructor is payable to support * prefunding during deployment. * @param _resolver Business-logic resolver used to resolve selectors to facet addresses. - * @param _resolverProxyConfigurationId Configuration identifier served by this proxy. - * @param _version Configuration version pinned for selector resolution. + * @param _resolverProxyConfigurationV2 Full V2 configuration served by this proxy. * @param _rbac Role assignments granted during initialisation. */ constructor( IBusinessLogicResolver _resolver, - bytes32 _resolverProxyConfigurationId, - uint256 _version, + IResolverProxy.ResolverProxyConfigurationV2 memory _resolverProxyConfigurationV2, IResolverProxy.Rbac[] memory _rbac ) payable { - _initialize(_resolver, _resolverProxyConfigurationId, _version, _rbac); + _initialize(_resolver, _resolverProxyConfigurationV2, _rbac); } /** diff --git a/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxyUnstructured.sol b/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxyUnstructured.sol index 37ef247585..b7444e250f 100644 --- a/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxyUnstructured.sol +++ b/packages/ats/contracts/contracts/infrastructure/proxy/ResolverProxyUnstructured.sol @@ -21,57 +21,38 @@ import { AccessControlStorageWrapper, RoleDataStorage } from "../../domain/core/ abstract contract ResolverProxyUnstructured { using AccessControlStorageWrapper for RoleDataStorage; + modifier onlyRegisteredResolverProxyConfiguration( + IBusinessLogicResolver _resolver, + bytes32 _configurationId, + uint256 _configurationVersion + ) { + _checkResolverProxyConfigurationRegistered(_resolver, _configurationId, _configurationVersion); + _; + } + /** * @notice Initialises resolver-proxy storage and grants initial RBAC roles. * @dev Requires the resolver to recognise the configuration id and version before storage is * written. Grants each role to each supplied member and may revert from resolver or access * control validation. Intended to be called once during construction or initialisation. * @param _resolver Business-logic resolver used for facet and interface resolution. - * @param _resolverProxyConfigurationId Configuration identifier served by this proxy. - * @param _version Configuration version pinned for selector resolution. + * @param _resolverProxyConfigurationV2 Configuration V2 struct served by this proxy. * @param _rbacs Initial role assignments to grant. */ function _initialize( IBusinessLogicResolver _resolver, - bytes32 _resolverProxyConfigurationId, - uint256 _version, + IResolverProxy.ResolverProxyConfigurationV2 memory _resolverProxyConfigurationV2, IResolverProxy.Rbac[] memory _rbacs ) internal { - _resolver.checkResolverProxyConfigurationRegistered(_resolverProxyConfigurationId, _version); - ResolverProxyStorageWrapper.initResolverProxyStorage(_resolver, _resolverProxyConfigurationId, _version); + _checkResolverProxyConfigurationRegistered( + _resolver, + _resolverProxyConfigurationV2.configurationId, + _resolverProxyConfigurationV2.configurationVersion + ); + ResolverProxyStorageWrapper.initResolverProxyStorage(_resolver, _resolverProxyConfigurationV2); _assignRbacRoles(_rbacs); } - /** - * @notice Updates the business-logic resolver used by the proxy. - * @dev Mutates resolver-proxy storage only. Callers must enforce authorisation and ensure the - * new resolver is compatible with the current configuration id and version. - * @param _resolver New resolver used for future facet and interface resolution. - */ - function _updateResolver(IBusinessLogicResolver _resolver) internal { - ResolverProxyStorageWrapper.setBusinessLogicResolver(_resolver); - } - - /** - * @notice Updates the resolver-proxy configuration identifier. - * @dev Mutates resolver-proxy storage only. Callers must validate that the active resolver - * supports the new configuration for the current version. - * @param _resolverProxyConfigurationId New configuration identifier served by this proxy. - */ - function _updateConfigId(bytes32 _resolverProxyConfigurationId) internal { - ResolverProxyStorageWrapper.setResolverProxyConfigurationId(_resolverProxyConfigurationId); - } - - /** - * @notice Updates the resolver-proxy configuration version. - * @dev Mutates resolver-proxy storage only. Callers must validate that the active resolver - * supports the new version for the current configuration identifier. - * @param _version New configuration version used for future selector resolution. - */ - function _updateVersion(uint256 _version) internal { - ResolverProxyStorageWrapper.setResolverProxyVersion(_version); - } - /** * @notice Grants batches of RBAC roles to their configured members. * @dev Iterates over every role/member pair and mutates access-control storage. Duplicate @@ -99,12 +80,10 @@ abstract contract ResolverProxyUnstructured { * @return facetsLength_ Number of facets registered for the active configuration version. */ function _getFacetsLength() internal view returns (uint256 facetsLength_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); facetsLength_ = ResolverProxyStorageWrapper .getBusinessLogicResolver() - .getFacetsLengthByConfigurationIdAndVersion( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion() - ); + .getFacetsLengthByConfigurationIdAndVersion(configId, versionId); } /** @@ -119,9 +98,11 @@ abstract contract ResolverProxyUnstructured { uint256 _pageIndex, uint256 _pageLength ) internal view returns (IDiamondLoupe.Facet[] memory facets_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facets_ = ResolverProxyStorageWrapper.getBusinessLogicResolver().getFacetsByConfigurationIdAndVersion( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _pageIndex, _pageLength ); @@ -135,13 +116,11 @@ abstract contract ResolverProxyUnstructured { * @return facetSelectorsLength_ Number of selectors registered for the facet. */ function _getFacetSelectorsLength(bytes32 _facetId) internal view returns (uint256 facetSelectorsLength_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facetSelectorsLength_ = ResolverProxyStorageWrapper .getBusinessLogicResolver() - .getFacetSelectorsLengthByConfigurationIdVersionAndFacetId( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), - _facetId - ); + .getFacetSelectorsLengthByConfigurationIdVersionAndFacetId(configId, versionId, _facetId); } /** @@ -158,11 +137,13 @@ abstract contract ResolverProxyUnstructured { uint256 _pageIndex, uint256 _pageLength ) internal view returns (bytes4[] memory facetSelectors_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facetSelectors_ = ResolverProxyStorageWrapper .getBusinessLogicResolver() .getFacetSelectorsByConfigurationIdVersionAndFacetId( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _facetId, _pageIndex, _pageLength @@ -178,9 +159,11 @@ abstract contract ResolverProxyUnstructured { * @return facetIds_ Page of facet identifiers. */ function _getFacetIds(uint256 _pageIndex, uint256 _pageLength) internal view returns (bytes32[] memory facetIds_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facetIds_ = ResolverProxyStorageWrapper.getBusinessLogicResolver().getFacetIdsByConfigurationIdAndVersion( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _pageIndex, _pageLength ); @@ -198,14 +181,11 @@ abstract contract ResolverProxyUnstructured { uint256 _pageIndex, uint256 _pageLength ) internal view returns (address[] memory facetAddresses_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facetAddresses_ = ResolverProxyStorageWrapper .getBusinessLogicResolver() - .getFacetAddressesByConfigurationIdAndVersion( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), - _pageIndex, - _pageLength - ); + .getFacetAddressesByConfigurationIdAndVersion(configId, versionId, _pageIndex, _pageLength); } /** @@ -216,9 +196,11 @@ abstract contract ResolverProxyUnstructured { * @return facetId_ Facet identifier associated with the selector. */ function _getFacetIdBySelector(bytes4 _selector) internal view returns (bytes32 facetId_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facetId_ = ResolverProxyStorageWrapper.getBusinessLogicResolver().getFacetIdByConfigurationIdVersionAndSelector( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _selector ); } @@ -230,9 +212,11 @@ abstract contract ResolverProxyUnstructured { * @return facet_ Facet metadata registered for the identifier. */ function _getFacet(bytes32 _facetId) internal view returns (IDiamondLoupe.Facet memory facet_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + facet_ = ResolverProxyStorageWrapper.getBusinessLogicResolver().getFacetByConfigurationIdVersionAndFacetId( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _facetId ); } @@ -247,8 +231,7 @@ abstract contract ResolverProxyUnstructured { function _getFacetAddress(bytes4 _selector) internal view returns (address) { return ResolverProxyStorageWrapper.getBusinessLogicResolver().resolveResolverProxyCall( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + ResolverProxyStorageWrapper.getProxyConfiguration(), _selector ); } @@ -260,10 +243,20 @@ abstract contract ResolverProxyUnstructured { * @return isSupported_ True when the active configuration supports the interface. */ function _supportsInterface(bytes4 _interfaceId) internal view returns (bool isSupported_) { + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + isSupported_ = ResolverProxyStorageWrapper.getBusinessLogicResolver().resolveSupportsInterface( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), + configId, + versionId, _interfaceId ); } + + function _checkResolverProxyConfigurationRegistered( + IBusinessLogicResolver _resolver, + bytes32 _configurationId, + uint256 _configurationVersion + ) private { + _resolver.checkResolverProxyConfigurationRegistered(_configurationId, _configurationVersion); + } } diff --git a/packages/ats/contracts/contracts/test/mocks/MockDiamondCut.sol b/packages/ats/contracts/contracts/test/mocks/MockDiamondCut.sol index f5618bcb5e..7b47054f3b 100644 --- a/packages/ats/contracts/contracts/test/mocks/MockDiamondCut.sol +++ b/packages/ats/contracts/contracts/test/mocks/MockDiamondCut.sol @@ -146,8 +146,8 @@ contract MockDiamondCut is IDiamond, IDiamondFacet, DiamondCut, DiamondLoupe, In /// @inheritdoc IMockDiamondCut /// @dev Writes status `0` for the active resolver proxy configuration and version. function forceNonOperational() external override { - bytes32 configId = ResolverProxyStorageWrapper.getResolverProxyConfigurationId(); - uint256 versionId = ResolverProxyStorageWrapper.getResolverProxyVersion(); + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + InitializerStorageWrapper.setConfigVersion(configId, versionId, 0); } @@ -155,14 +155,12 @@ contract MockDiamondCut is IDiamond, IDiamondFacet, DiamondCut, DiamondLoupe, In /// @dev Resolves the current facet version through the business logic resolver and resets /// both its version status and last-version pointer. function forceFacetNotRegistered(bytes32 _facetKey) external override { - uint256 versionId = ResolverProxyStorageWrapper + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + + uint256 facetVersionId = ResolverProxyStorageWrapper .getBusinessLogicResolver() - .getFacetVersionByConfigurationIdVersionAndFacetId( - ResolverProxyStorageWrapper.getResolverProxyConfigurationId(), - ResolverProxyStorageWrapper.getResolverProxyVersion(), - _facetKey - ); - InitializerStorageWrapper.setFacetStatusForVersion(_facetKey, versionId, 0); + .getFacetVersionByConfigurationIdVersionAndFacetId(configId, versionId, _facetKey); + InitializerStorageWrapper.setFacetStatusForVersion(_facetKey, facetVersionId, 0); InitializerStorageWrapper.setFacetLastVersionTo(_facetKey, 0); } @@ -189,8 +187,8 @@ contract MockDiamondCut is IDiamond, IDiamondFacet, DiamondCut, DiamondLoupe, In /// walking the configured facet list. The caller is responsible for ensuring every /// required facet has already been marked ready. function forceSetOperational() external override { - bytes32 configId = ResolverProxyStorageWrapper.getResolverProxyConfigurationId(); - uint256 versionId = ResolverProxyStorageWrapper.getResolverProxyVersion(); + (bytes32 configId, uint256 versionId) = ResolverProxyStorageWrapper.getResolverProxyConfigurationIdAndVersion(); + InitializerStorageWrapper.setConfigVersion(configId, versionId, 1); } diff --git a/packages/ats/contracts/contracts/test/mocks/MockFactory.sol b/packages/ats/contracts/contracts/test/mocks/MockFactory.sol index 25166c7c9d..dc77d9eb56 100644 --- a/packages/ats/contracts/contracts/test/mocks/MockFactory.sol +++ b/packages/ats/contracts/contracts/test/mocks/MockFactory.sol @@ -230,7 +230,13 @@ abstract contract MockFactory is Factory, IMockFactory { // 2. Deploy a bare ResolverProxy against ASSET_MOCK_CONFIG_ID, version 1. // Mirrors Factory._deploySecurityProxy but creates the proxy directly // without the SecurityData indirection (no ISIN, regulation, etc.). - ResolverProxy proxy = new ResolverProxy(resolver_, _ASSET_MOCK_CONFIG_ID, 1, rbacs); + IResolverProxy.ResolverProxyConfigurationV2 memory resolverProxyConfig = IResolverProxy + .ResolverProxyConfigurationV2({ + configurationId: _ASSET_MOCK_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: false + }); + ResolverProxy proxy = new ResolverProxy(resolver_, resolverProxyConfig, rbacs); assetAddress_ = address(proxy); // 3. Read the full facet list from the BLR for the AssetMock config diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IBusinessLogicResolverV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IBusinessLogicResolverV1.sol new file mode 100644 index 0000000000..33078123f3 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IBusinessLogicResolverV1.sol @@ -0,0 +1,152 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; +import { IDiamondCutManagerV1 } from "./IDiamondCutManagerV1.sol"; + +/** + * @title Contracts Repository + * @notice This contract is used to register and resolve Business Logics (aka contracts) addresses using + * a bytes32 as key. + * + * All registered Business Logics must have the same number of versions, so that they have a common "latest" + * version and any previous version can be resolved for any existing Business Logic no matter when it was + * added to the register. + * The idea is that consumers should use Business Logics belonging to the same version since those are + * considered fully compatible. + * Registering a business logic (register = update its latest version or add it to the registry) will increase the + * latest version for all Business Logics by 1. + */ +interface IBusinessLogicResolverV1 is IDiamondCutManagerV1 { + enum VersionStatus { + NONE, + ACTIVATED, + DEACTIVATED + } + + /// @notice structure defining the input data type when registering or updating business logics + struct BusinessLogicRegistryData { + bytes32 businessLogicKey; + address businessLogicAddress; + } + + /// @notice structure defining the a given Version status + struct VersionData { + uint256 version; + VersionStatus status; + } + + struct BusinessLogicVersion { + VersionData versionData; + address businessLogicAddress; + } + + /// @notice Emitted once when the BLR itself is initialised. + /// @dev Fires exclusively from `initializeBusinessLogicResolver` after the storage write succeeds. + event BusinessLogicResolverInitialized(); + + /// @notice Event emitted when Business Logic(s) are registered (updated or added). + /// @param businessLogics list of registered Business Logics. + /// @param newLatestVersions new latest version per registered key, in the same order as `businessLogics`. + event BusinessLogicsRegistered(BusinessLogicRegistryData[] businessLogics, uint256[] newLatestVersions); + + error BusinessLogicVersionDoesNotExist(uint256 version); + error BusinessLogicKeyDuplicated(bytes32 businessLogicKey); + error BusinessLogicKeyMismatch(address implementation, bytes32 actualKey, bytes32 expectedKey); + error ZeroKeyNotValidForBusinessLogic(); + + function initializeBusinessLogicResolver() external returns (bool success_); + + /** + * @notice Update existing business logics addresses or add new business logics to the register. + * the BusinessLogicsRegistered event must be emitted. + * The latest "version" for all business logics is increased by 1. + * @param _businessLogics list of business logics to be registered. + */ + function registerBusinessLogics(BusinessLogicRegistryData[] calldata _businessLogics) external; + + /** + * @notice Adds a list of selectors to the blacklist + * @param _configurationId the configuration key to be checked. + * @param _selectors list of selectors to be added to the blacklist + */ + function addSelectorsToBlacklist(bytes32 _configurationId, bytes4[] calldata _selectors) external; + + /** + * @notice Removes a list of selectors from the blacklist + * @param _configurationId the configuration key to be checked. + * @param _selectors list of selectors to be removed from the blacklist + */ + function removeSelectorsFromBlacklist(bytes32 _configurationId, bytes4[] calldata _selectors) external; + + /** + * @notice Returns the current status of a given version + */ + function getVersionStatus( + bytes32 _businessLogicKey, + uint256 _version + ) external view returns (VersionStatus status_); + + /** + * @notice Returns the current latest version for all business logics + */ + function getLatestVersion(bytes32 _businessLogicKey) external view returns (uint256 latestVersion_); + + /** + * @notice Batched variant of `getLatestVersion` that resolves many keys in a single call. + * @dev Issued so off-chain consumers can avoid one `eth_call` per key — JSON-RPC relays + * such as Hedera's enforce per-IP rate limits on `eth_call` and reject bursts. + * Returns 0 for keys that have never been registered (same semantics as the scalar + * variant). + * @param _businessLogicKeys keys of the business logics to query. + * @return latestVersions_ latest version per key, in the same order as `_businessLogicKeys`. + */ + function getLatestVersions( + bytes32[] calldata _businessLogicKeys + ) external view returns (uint256[] memory latestVersions_); + + /** + * @notice Returns the business logic address for the latest version + * @param _businessLogicKey key of the business logic. Business Logic must be active. + */ + function resolveLatestBusinessLogic( + bytes32 _businessLogicKey + ) external view returns (address businessLogicAddress_); + + /** + * @notice Returns a specific business logic version address + * @param _businessLogicKey key of the business logic. Business Logic must be active. + * @param _version the version + */ + function resolveBusinessLogicByVersion( + bytes32 _businessLogicKey, + uint256 _version + ) external view returns (address businessLogicAddress_); + + /** + * @notice Returns the count of currently active business logics + */ + function getBusinessLogicCount() external view returns (uint256 businessLogicCount_); + + /** + * @notice Returns a list of business logic keys + * @param _pageIndex members to skip : _pageIndex * _pageLength + * @param _pageLength number of members to return + * @return businessLogicKeys_ list of business logic keys + */ + function getBusinessLogicKeys( + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes32[] memory businessLogicKeys_); + + /** + * @notice Returns the list of selectors in the blacklist + * @param _configurationId the configuration key to be checked. + * @param _pageIndex members to skip : _pageIndex * _pageLength + * @param _pageLength number of members to return + * @return selectors_ List of the selectors in the blacklist + */ + function getSelectorsBlacklist( + bytes32 _configurationId, + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes4[] memory selectors_); +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondCutManagerV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondCutManagerV1.sol new file mode 100644 index 0000000000..d03fc8ceb1 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondCutManagerV1.sol @@ -0,0 +1,448 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { IDiamondLoupeV1 } from "./IDiamondLoupeV1.sol"; + +/** + * @title IDiamondCutManagerV1 + * @author Asset Tokenization Studio Team + * @notice Manages versioned diamond configurations consumed by resolver proxies. + * @dev Each configuration is keyed by `configurationId` and groups a set of facets at pinned + * versions. For every configurationId the manager retains: + * - `latestVersion`: monotonically increasing counter of registered versions. + * - Per version: the facet list, where each entry exposes the facet id, its selectors, + * and its supported interface ids. + * Configurations may be registered atomically via {createConfiguration} or incrementally + * via {createBatchConfiguration}, with {cancelBatchConfiguration} discarding an + * in-progress batch. Resolution helpers ({resolveResolverProxyCall}, + * {resolveSupportsInterface}) drive the dispatch logic of resolver proxies and require an + * explicit non-zero `_version`; callers that want the most recent version must read it + * first via {getLatestVersionByConfiguration}. Read helpers expose paginated views over + * configurations, facets, and selectors to keep gas bounded. + */ +interface IDiamondCutManagerV1 { + /** + * @notice Tuple identifying a facet at a specific version inside a configuration. + * @dev Used as input by configuration-creation entrypoints. `id` references a facet + * previously registered in the business-logic resolver; `version` pins the version + * to snapshot inside the configuration. + * @param id Facet identifier (business-logic key). + * @param version Facet version to pin; must be > 0. The business-logic resolver rejects + * 0 with {IBusinessLogicResolver.BusinessLogicVersionDoesNotExist}. + */ + struct FacetConfiguration { + bytes32 id; + uint256 version; + } + + /** + * @notice Emitted when a configuration is created atomically via {createConfiguration}. + * @param configurationId Configuration key that was registered. + * @param facetConfigurations Facets (id, version) that compose the new configuration. + * @param version Version number assigned to the newly created configuration. + * @param data Additional data passed to the configuration. + */ + event DiamondConfigurationCreated( + bytes32 configurationId, + FacetConfiguration[] facetConfigurations, + uint256 version, + bytes data + ); + + /** + * @notice Emitted on every {createBatchConfiguration} call, including the final batch. + * @param configurationId Configuration key being assembled. + * @param facetConfigurations Facets appended in this batch. + * @param _isLastBatch True when this call finalises the configuration version. + * @param version Version number being assembled for this configuration. + * @param data Additional data passed to the configuration. + */ + event DiamondBatchConfigurationCreated( + bytes32 configurationId, + FacetConfiguration[] facetConfigurations, + bool _isLastBatch, + uint256 version, + bytes data + ); + + /** + * @notice Emitted when an in-progress batch configuration is discarded. + * @param configurationId Configuration key whose pending batch was cancelled. + * @param version Version number that was being assembled and is now dropped. + */ + event DiamondBatchConfigurationCanceled(bytes32 indexed configurationId, uint256 version); + + /// @notice Thrown when `bytes32(0)` is supplied as a configuration id, which is reserved. + error DefaultValueForConfigurationIdNotPermitted(); + + /** + * @notice Thrown when attempting to activate a configuration that contains no facets, + * which would brick any ResolverProxy following the latest version. + * @param configurationId Configuration key that was supplied with an empty facet list. + */ + error EmptyFacetConfigurationNotPermitted(bytes32 configurationId); + + /** + * @notice Thrown when a configuration references a facet id that is not registered in + * the business-logic resolver. + * @param configurationId Configuration being created or modified. + * @param facetId Unknown facet id that triggered the revert. + */ + error FacetIdNotRegistered(bytes32 configurationId, bytes32 facetId); + + /** + * @notice Thrown when the same facet id appears more than once within a configuration. + * @param facetId Duplicated facet id. + */ + error DuplicatedFacetInConfiguration(bytes32 facetId); + + /** + * @notice Thrown when {createConfiguration} is called for a configuration id that already + * has an in-progress batch, which would prematurely finalise the incomplete batch + * and absorb any facets that were intended for subsequent batch additions. + * @param configurationId Configuration key whose batch is currently open. + */ + error OngoingBatchConfigurationNotPermitted(bytes32 configurationId); + + /** + * @notice Thrown when a (configurationId, version) pair is referenced but has not been + * registered (or is still mid-batch and therefore not yet finalised). + * @param resolverProxyConfigurationId Configuration key that was looked up. + * @param version Version that was looked up. + */ + error ResolverProxyConfigurationNoRegistered(bytes32 resolverProxyConfigurationId, uint256 version); + + /** + * @notice Thrown when a configuration version of 0 is supplied to an entry point that + * requires an explicit version pin. + * @dev Callers that want the most recent registered version must read it first via + * {getLatestVersionByConfiguration} and pass that value. + * @param configurationId Configuration key that was looked up. + */ + error VersionZero(bytes32 configurationId); + + /** + * @notice Thrown when attempting to register a selector that is globally blacklisted. + * @param selector Function selector that is forbidden. + */ + error SelectorBlacklisted(bytes4 selector); + + /** + * @notice Thrown when a selector is already registered under another facet for the same + * (configurationId, version), which would create an ambiguous dispatch. + * @param configurationId Configuration where the clash was detected. + * @param version Version where the clash was detected. + * @param facetId Facet attempting to register the selector. + * @param selector Selector that is already mapped to a different facet. + */ + error SelectorAlreadyRegistered(bytes32 configurationId, uint256 version, bytes32 facetId, bytes4 selector); + + /** + * @notice Registers a new configuration atomically, pinning each facet at the supplied + * version. + * @dev Reverts with {DefaultValueForConfigurationIdNotPermitted}, + * {FacetIdNotRegistered}, {DuplicatedFacetInConfiguration}, {SelectorBlacklisted} + * or {SelectorAlreadyRegistered} on invalid input. Facet versions must be > 0; + * the business-logic resolver rejects 0. Emits {DiamondConfigurationCreated} on + * success. + * @param _configurationId Unique configuration key to register; must not be `bytes32(0)`. + * @param _facetConfigurations List of facets (id + pinned version) composing the + * configuration; facet ids must be unique within the list. + * @param _data Additional data to be passed to the configuration. + */ + function createConfiguration( + bytes32 _configurationId, + FacetConfiguration[] calldata _facetConfigurations, + bytes calldata _data + ) external; + + /** + * @notice Appends facets to a configuration in batches; the configuration becomes + * resolvable only after the call flagged as the last batch. + * @dev Each invocation emits {DiamondBatchConfigurationCreated}. Until `_isLastBatch` + * is true the (configurationId, version) pair is not registered and resolution + * helpers continue to revert with {ResolverProxyConfigurationNoRegistered}. + * @param _configurationId Configuration key being assembled; must not be `bytes32(0)`. + * @param _facetConfigurations Facets appended in this batch; ids must remain unique + * across all batches contributing to the same version. + * @param _isLastBatch True to finalise and register the version, false to keep + * accepting further batches. + * @param _data Additional data to be passed to the configuration. + */ + function createBatchConfiguration( + bytes32 _configurationId, + FacetConfiguration[] calldata _facetConfigurations, + bool _isLastBatch, + bytes calldata _data + ) external; + + /** + * @notice Discards an in-progress batch configuration, dropping every facet appended so + * far for the pending version. + * @dev Emits {DiamondBatchConfigurationCanceled}. Has no effect once the version has + * been finalised via a `_isLastBatch = true` call. + * @param _configurationId Configuration key whose pending batch should be cancelled. + */ + function cancelBatchConfiguration(bytes32 _configurationId) external; + + /** + * @notice Reverts if the (configurationId, version) pair is not a registered, finalised + * configuration. + * @dev Intended to gate resolver-proxy operations; reverts with + * {ResolverProxyConfigurationNoRegistered} when the lookup fails. + * @param _configurationId Configuration key to verify. + * @param _version Version to verify; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + */ + function checkResolverProxyConfigurationRegistered(bytes32 _configurationId, uint256 _version) external; + + /** + * @notice Resolves the facet address that implements a selector for a given + * configuration and version. + * @dev Used by resolver proxies during dispatch. Returns `address(0)` when no facet + * claims the selector. + * @param _configurationId Configuration key bound to the resolver proxy. + * @param _version Version bound to the resolver proxy; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _selector Function selector being dispatched. + * @return facetAddress_ Address of the facet that owns `_selector`, or `address(0)` if + * the selector is not registered for the given configuration/version. + */ + function resolveResolverProxyCall( + bytes32 _configurationId, + uint256 _version, + bytes4 _selector + ) external view returns (address facetAddress_); + + /** + * @notice Reports whether an interface id is advertised by any facet inside the given + * configuration and version. + * @dev Powers ERC-165 lookups on resolver proxies. + * @param _configurationId Configuration key bound to the resolver proxy. + * @param _version Version bound to the resolver proxy; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _interfaceId Interface identifier to test. + * @return exists_ True if `_interfaceId` is supported by the configuration version. + */ + function resolveSupportsInterface( + bytes32 _configurationId, + uint256 _version, + bytes4 _interfaceId + ) external view returns (bool exists_); + + /** + * @notice Non-reverting variant of {checkResolverProxyConfigurationRegistered}. + * @param _configurationId Configuration key to check. + * @param _version Version to check; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @return True when the configuration version is registered and finalised. + */ + function isResolverProxyConfigurationRegistered( + bytes32 _configurationId, + uint256 _version + ) external view returns (bool); + + /** + * @notice Returns the number of distinct configuration keys registered in the manager. + * @return configurationsLength_ Total count of registered configuration ids. + */ + function getConfigurationsLength() external view returns (uint256 configurationsLength_); + + /** + * @notice Returns a paginated slice of registered configuration ids. + * @dev Pagination is used to keep gas bounded on large registries; out-of-range pages + * return an empty array rather than reverting. + * @param _pageIndex Page index; entries skipped equal `_pageIndex * _pageLength`. + * @param _pageLength Maximum number of entries to return. + * @return configurationIds_ Slice of configuration ids for the requested page. + */ + function getConfigurations( + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes32[] memory configurationIds_); + + /** + * @notice Returns the latest registered version of a configuration. + * @param _configurationId Configuration key to query. + * @return latestVersion_ Latest finalised version, or 0 when no version is registered. + */ + function getLatestVersionByConfiguration(bytes32 _configurationId) external view returns (uint256 latestVersion_); + + /** + * @notice Returns the number of facets registered under a configuration version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @return facetsLength_ Count of facets in the configuration version. + */ + function getFacetsLengthByConfigurationIdAndVersion( + bytes32 _configurationId, + uint256 _version + ) external view returns (uint256 facetsLength_); + + /** + * @notice Returns a paginated slice of facets for a configuration version, including + * each facet's address, selectors, and advertised interface ids. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _pageIndex Page index; entries skipped equal `_pageIndex * _pageLength`. + * @param _pageLength Maximum number of entries to return. + * @return facets_ Slice of {IDiamondLoupeV1.Facet} entries for the requested page. + */ + function getFacetsByConfigurationIdAndVersion( + bytes32 _configurationId, + uint256 _version, + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (IDiamondLoupeV1.Facet[] memory facets_); + + /** + * @notice Returns the number of selectors registered for a facet inside a configuration + * version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _facetId Facet key whose selectors are counted. + * @return facetSelectorsLength_ Count of selectors owned by the facet in the version. + */ + function getFacetSelectorsLengthByConfigurationIdVersionAndFacetId( + bytes32 _configurationId, + uint256 _version, + bytes32 _facetId + ) external view returns (uint256 facetSelectorsLength_); + + /** + * @notice Returns a paginated slice of selectors registered for a facet inside a + * configuration version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _facetId Facet key whose selectors are returned. + * @param _pageIndex Page index; entries skipped equal `_pageIndex * _pageLength`. + * @param _pageLength Maximum number of entries to return. + * @return facetSelectors_ Slice of selectors for the requested page. + */ + function getFacetSelectorsByConfigurationIdVersionAndFacetId( + bytes32 _configurationId, + uint256 _version, + bytes32 _facetId, + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes4[] memory facetSelectors_); + + /** + * @notice Returns a paginated slice of facet ids registered for a configuration version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _pageIndex Page index; entries skipped equal `_pageIndex * _pageLength`. + * @param _pageLength Maximum number of entries to return. + * @return facetIds_ Slice of facet ids for the requested page. + */ + function getFacetIdsByConfigurationIdAndVersion( + bytes32 _configurationId, + uint256 _version, + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes32[] memory facetIds_); + + /** + * @notice Returns the (facet id, facet version) tuples registered for a configuration + * version over a half-open index range. + * @dev Slice semantics differ from the page-based helpers: `_start` is inclusive and + * `_end` is exclusive, allowing callers to express arbitrary windows. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _start Inclusive start index of the slice. + * @param _end Exclusive end index of the slice. + * @return facetConfigurations_ Slice of {FacetConfiguration} entries for the window. + */ + function getFacetConfigurationsByConfigurationIdAndVersion( + bytes32 _configurationId, + uint256 _version, + uint256 _start, + uint256 _end + ) external view returns (FacetConfiguration[] memory facetConfigurations_); + + /** + * @notice Returns a paginated slice of facet addresses registered for a configuration + * version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _pageIndex Page index; entries skipped equal `_pageIndex * _pageLength`. + * @param _pageLength Maximum number of entries to return. + * @return facetAddresses_ Slice of facet addresses for the requested page. + */ + function getFacetAddressesByConfigurationIdAndVersion( + bytes32 _configurationId, + uint256 _version, + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (address[] memory facetAddresses_); + + /** + * @notice Returns the facet id that owns a selector inside a configuration version. + * @dev Returns `bytes32(0)` when the selector is not registered. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _selector Selector to look up. + * @return facetId_ Facet id owning `_selector`, or `bytes32(0)` if none. + */ + function getFacetIdByConfigurationIdVersionAndSelector( + bytes32 _configurationId, + uint256 _version, + bytes4 _selector + ) external view returns (bytes32 facetId_); + + /** + * @notice Returns the full facet record (id, address, selectors, interface ids) for a + * facet inside a configuration version. + * @dev Returns a zero-valued {IDiamondLoupeV1.Facet} when the facet is not part of the + * configuration version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _facetId Facet key to look up. + * @return facet_ Facet record for `_facetId`. + */ + function getFacetByConfigurationIdVersionAndFacetId( + bytes32 _configurationId, + uint256 _version, + bytes32 _facetId + ) external view returns (IDiamondLoupeV1.Facet memory facet_); + + /** + * @notice Returns the address of a facet inside a configuration version. + * @dev Returns `address(0)` when the facet is not part of the configuration version. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _facetId Facet key to look up. + * @return facetAddress_ Address of the facet, or `address(0)` if unregistered. + */ + function getFacetAddressByConfigurationIdVersionAndFacetId( + bytes32 _configurationId, + uint256 _version, + bytes32 _facetId + ) external view returns (address facetAddress_); + + /** + * @notice Returns the pinned facet version stored inside a configuration version. + * @dev Reverts with {FacetIdNotRegistered} when the facet is not part of the configuration + * version, and with {VersionZero} when `_version` is 0. + * @param _configurationId Configuration key to query. + * @param _version Version to query; must be > 0. Read + * {getLatestVersionByConfiguration} first when the latest is required. + * @param _facetId Facet key to look up. + * @return facetVersion_ Pinned facet version inside the configuration version. + */ + function getFacetVersionByConfigurationIdVersionAndFacetId( + bytes32 _configurationId, + uint256 _version, + bytes32 _facetId + ) external view returns (uint256 facetVersion_); +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondLoupeV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondLoupeV1.sol new file mode 100644 index 0000000000..e21a13ff14 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondLoupeV1.sol @@ -0,0 +1,118 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { IStaticFunctionSelectorsV1 } from "./IStaticFunctionSelectorsV1.sol"; + +interface IDiamondLoupeV1 is IStaticFunctionSelectorsV1 { + struct Facet { + bytes32 id; + address addr; + bytes4[] selectors; + bytes4[] interfaceIds; + } + + /** + * @notice Gets all facet addresses and their four byte function selectors. + * @return facets_ Facet + */ + function getFacets() external view returns (Facet[] memory facets_); + + /** + * @notice Gets facet length. + * @return facetsLength_ Facets length + */ + function getFacetsLength() external view returns (uint256 facetsLength_); + + /** + * @notice Gets all facet addresses and their four byte function selectors. + * @param _pageIndex members to skip : _pageIndex * _pageLength + * @param _pageLength number of members to return + * @return facets_ Facet + */ + function getFacetsByPage(uint256 _pageIndex, uint256 _pageLength) external view returns (Facet[] memory facets_); + + /** + * @notice Gets all the function selectors supported by a specific facet. + * @param _facetId The facet key for the resolver. + * @return facetSelectors_ + */ + function getFacetSelectors(bytes32 _facetId) external view returns (bytes4[] memory facetSelectors_); + + /** + * @notice Gets the function selectors length. + * @param _facetId The facet key for the resolver. + * @return facetSelectorsLength_ + */ + function getFacetSelectorsLength(bytes32 _facetId) external view returns (uint256 facetSelectorsLength_); + + /** + * @notice Gets all the function selectors supported by a specific facet. + * @param _facetId The facet key for the resolver. + * @param _pageIndex members to skip : _pageIndex * _pageLength + * @param _pageLength number of members to return + * @return facetSelectors_ + */ + function getFacetSelectorsByPage( + bytes32 _facetId, + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes4[] memory facetSelectors_); + + /** + * @notice Get all the facet addresses used by a resolverProxy + * @return facetIds_ + */ + function getFacetIds() external view returns (bytes32[] memory facetIds_); + + /** + * @notice Get all the facet addresses used by a resolverProxy + * @param _pageIndex members to skip : _pageIndex * _pageLength + * @param _pageLength number of members to return + * @return facetIds_ + */ + function getFacetIdsByPage( + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (bytes32[] memory facetIds_); + + /** + * @notice Get all the facet addresses used by a resolverProxy + * @return facetAddresses_ + */ + function getFacetAddresses() external view returns (address[] memory facetAddresses_); + + /** + * @notice Get all the facet addresses used by a resolverProxy + * @param _pageIndex members to skip : _pageIndex * _pageLength + * @param _pageLength number of members to return + * @return facetAddresses_ + */ + function getFacetAddressesByPage( + uint256 _pageIndex, + uint256 _pageLength + ) external view returns (address[] memory facetAddresses_); + + /** + * @notice Gets the facet key that supports the given selector + * @dev If facet is not found return address(0) + * @param _selector The function selector + * @return facetId_ The facet key + */ + function getFacetIdBySelector(bytes4 _selector) external view returns (bytes32 facetId_); + + /** + * @notice Get the information associated with an specific facet + * @dev If facet is not found return empty Facet struct + * @param _facetId The facet key for the resolver + * @return facet_ Facet data + */ + function getFacet(bytes32 _facetId) external view returns (Facet memory facet_); + + /** + * @notice Gets the facet that supports the given selector + * @dev If facet is not found return address(0) + * @param _selector The function selector + * @return facetAddress_ The facet address + */ + function getFacetAddress(bytes4 _selector) external view returns (address facetAddress_); +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondV1.sol new file mode 100644 index 0000000000..209f4c670e --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IDiamondV1.sol @@ -0,0 +1,16 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; +import { IDiamondCutV1 } from "./diamondFacet/IDiamondCutV1.sol"; +import { IDiamondLoupeV1 } from "./IDiamondLoupeV1.sol"; + +/// @custom:hash resolverKey Diamond +bytes32 constant RESOLVER_KEY_DIAMOND = 0xd9202bb838fd8d0f2866f13141398cfb9fa74cbbbce7449c9158caffa9c509f4; + +/** + * @title IDiamond + * @author Asset Tokenization Studio Team + * @notice Umbrella interface combining the cut and loupe facets of the Diamond proxy. + * @dev Inherits `IDiamondCut` (facet upgrade operations) and `IDiamondLoupe` (introspection + * queries). Consumers that need to address the Diamond as a whole use this interface. + */ +interface IDiamondV1 is IDiamondCutV1, IDiamondLoupeV1 {} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IResolverProxyV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IResolverProxyV1.sol new file mode 100644 index 0000000000..45b99ca965 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IResolverProxyV1.sol @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +interface IResolverProxyV1 { + struct Rbac { + bytes32 role; + address[] members; + } + + /// @notice Thrown when no function exists for function called + error FunctionNotFound(bytes4 _functionSelector); +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IStaticFunctionSelectorsV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IStaticFunctionSelectorsV1.sol new file mode 100644 index 0000000000..82939869fc --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/IStaticFunctionSelectorsV1.sol @@ -0,0 +1,28 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +/** + * @title IStaticFunctionSelectors + * @author Asset Tokenization Studio Team + * @notice Interface that every Diamond facet must implement to expose its resolver key, + * function selectors, and interface identifiers for proxy registration. + */ +interface IStaticFunctionSelectorsV1 { + /** + * @notice Gets the static resolver key + * @return staticResolverKey_ Static resolver key + */ + function getStaticResolverKey() external pure returns (bytes32 staticResolverKey_); + + /** + * @notice Gets all function selectors of a facet + * @return staticFunctionSelectors_ Face functions selectors + */ + function getStaticFunctionSelectors() external pure returns (bytes4[] memory staticFunctionSelectors_); + + /** + * @notice Gets all interfaces ids of a facet. + * @return staticInterfaceIds_ Face interface ids + */ + function getStaticInterfaceIds() external pure returns (bytes4[] memory staticInterfaceIds_); +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyStorageWrapperV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyStorageWrapperV1.sol new file mode 100644 index 0000000000..c6ac9729bb --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyStorageWrapperV1.sol @@ -0,0 +1,114 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { IBusinessLogicResolverV1 } from "./IBusinessLogicResolverV1.sol"; + +/// @custom:hash storage ResolverProxy +bytes32 constant STORAGE_LOCATION_RESOLVER_PROXY = 0x688a1184cf65cae3790aef0eb6006209aa488bc22d1dd13eb263813b07a39300; + +/** + * @notice Storage layout backing a resolver-proxy instance. + * @dev Records the `BusinessLogicResolver` pointer, the active configuration identifier and the + * pinned configuration version that together select the facet selectors served by the proxy. + * New fields must be appended below the APPEND-ONLY marker to preserve upgrade safety. + * @custom:storage-location erc7201:security.token.standard.storage.ResolverProxy + */ +struct ResolverProxyStorage { + // ─── R1 Lifecycle (bool flags) ─────────────────────────── + // ─── R2 Packed scalars (uint8, bytes3, address, enum) ──── + IBusinessLogicResolverV1 resolver; + // ─── R3 Single-slot scalars (uint256, bytes32, string) ─── + bytes32 resolverProxyConfigurationId; + uint256 version; + // ─── R4 Aggregates (mapping, array, EnumerableSet) ─────── + // ─── APPEND-ONLY ZONE BELOW ─── +} + +/** + * @title ResolverProxyStorageWrapperV1 + * @author Asset Tokenization Studio Team + * @notice Internal library exposing read accessors for the resolver-proxy storage namespace. + * @dev Mutations of these fields happen at proxy construction or via privileged upgrade flows; + * this wrapper only surfaces the values to facets that need to introspect the active + * resolver, configuration identifier or version. + */ +library ResolverProxyStorageWrapperV1 { + /** + * @notice Initializes the resolver-proxy storage. + * @param _resolver The `BusinessLogicResolver` instance. + * @param _resolverProxyConfigurationId The configuration identifier. + * @param _version The configuration version. + */ + function initResolverProxyStorage( + IBusinessLogicResolverV1 _resolver, + bytes32 _resolverProxyConfigurationId, + uint256 _version + ) internal { + ResolverProxyStorage storage ds = resolverProxyStorage(); + ds.resolver = _resolver; + ds.resolverProxyConfigurationId = _resolverProxyConfigurationId; + ds.version = _version; + } + + /** + * @notice Updates the `BusinessLogicResolver` instance. + * @param _resolver The new resolver instance. + */ + function setBusinessLogicResolver(IBusinessLogicResolverV1 _resolver) internal { + resolverProxyStorage().resolver = _resolver; + } + + /** + * @notice Updates the configuration identifier. + * @param _resolverProxyConfigurationId The new configuration identifier. + */ + function setResolverProxyConfigurationId(bytes32 _resolverProxyConfigurationId) internal { + resolverProxyStorage().resolverProxyConfigurationId = _resolverProxyConfigurationId; + } + + /** + * @notice Updates the configuration version. + * @param _version The new configuration version. + */ + function setResolverProxyVersion(uint256 _version) internal { + resolverProxyStorage().version = _version; + } + + /** + * @notice Returns the `BusinessLogicResolver` contract that supplies the facet selectors. + * @return The active resolver instance for this proxy. + */ + function getBusinessLogicResolver() internal view returns (IBusinessLogicResolverV1) { + return resolverProxyStorage().resolver; + } + + /** + * @notice Returns the configuration identifier selecting the facet set served by the proxy. + * @return The configured `bytes32` identifier. + */ + function getResolverProxyConfigurationId() internal view returns (bytes32) { + return resolverProxyStorage().resolverProxyConfigurationId; + } + + /** + * @notice Returns the pinned configuration version served by the proxy. + * @return The configuration version, zero when the proxy tracks the latest. + */ + function getResolverProxyConfigurationVersion() internal view returns (uint256) { + return resolverProxyStorage().version; + } + + /** + * @notice Returns the storage pointer for the ResolverProxy namespace. + * @dev Resolves the ERC-7201 slot via inline assembly to obtain a struct reference at + * `STORAGE_LOCATION_RESOLVER_PROXY`. + * @return ds Storage reference to the `ResolverProxyStorage` struct. + */ + function resolverProxyStorage() private pure returns (ResolverProxyStorage storage ds) { + bytes32 position = STORAGE_LOCATION_RESOLVER_PROXY; + // solhint-disable-next-line no-inline-assembly + assembly { + ds.slot := position + } + } +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyUnstructuredV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyUnstructuredV1.sol new file mode 100644 index 0000000000..e7f3bda31d --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyUnstructuredV1.sol @@ -0,0 +1,256 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { IResolverProxyV1 } from "./IResolverProxyV1.sol"; +import { IBusinessLogicResolverV1 } from "./IBusinessLogicResolverV1.sol"; +import { IDiamondLoupeV1 } from "./IDiamondLoupeV1.sol"; +import { ResolverProxyStorageWrapperV1, ResolverProxyStorage } from "./ResolverProxyStorageWrapperV1.sol"; +import { AccessControlStorageWrapper, RoleDataStorage } from "../../../domain/core/AccessControlStorageWrapper.sol"; + +// Remember to add the loupe functions from DiamondLoupeFacet.sol.sol to the resolverProxy. +// The loupe functions are required by the EIP2535 ResolverProxys standard +abstract contract ResolverProxyUnstructuredV1 { + using AccessControlStorageWrapper for RoleDataStorage; + + /** + * @notice Initialises resolver-proxy storage and grants initial RBAC roles. + * @dev Requires the resolver to recognise the configuration id and version before storage is + * written. Grants each role to each supplied member and may revert from resolver or access + * control validation. Intended to be called once during construction or initialisation. + * @param _resolver Business-logic resolver used for facet and interface resolution. + * @param _resolverProxyConfigurationId Configuration identifier served by this proxy. + * @param _version Configuration version pinned for selector resolution. + * @param _rbacs Initial role assignments to grant. + */ + function _initialize( + IBusinessLogicResolverV1 _resolver, + bytes32 _resolverProxyConfigurationId, + uint256 _version, + IResolverProxyV1.Rbac[] memory _rbacs + ) internal { + _resolver.checkResolverProxyConfigurationRegistered(_resolverProxyConfigurationId, _version); + ResolverProxyStorageWrapperV1.initResolverProxyStorage(_resolver, _resolverProxyConfigurationId, _version); + _assignRbacRoles(_rbacs); + } + + /** + * @notice Updates the business-logic resolver used by the proxy. + * @dev Mutates resolver-proxy storage only. Callers must enforce authorisation and ensure the + * new resolver is compatible with the current configuration id and version. + * @param _resolver New resolver used for future facet and interface resolution. + */ + function _updateResolver(IBusinessLogicResolverV1 _resolver) internal { + ResolverProxyStorageWrapperV1.setBusinessLogicResolver(_resolver); + } + + /** + * @notice Updates the resolver-proxy configuration identifier. + * @dev Mutates resolver-proxy storage only. Callers must validate that the active resolver + * supports the new configuration for the current version. + * @param _resolverProxyConfigurationId New configuration identifier served by this proxy. + */ + function _updateConfigId(bytes32 _resolverProxyConfigurationId) internal { + ResolverProxyStorageWrapperV1.setResolverProxyConfigurationId(_resolverProxyConfigurationId); + } + + /** + * @notice Updates the resolver-proxy configuration version. + * @dev Mutates resolver-proxy storage only. Callers must validate that the active resolver + * supports the new version for the current configuration identifier. + * @param _version New configuration version used for future selector resolution. + */ + function _updateVersion(uint256 _version) internal { + ResolverProxyStorageWrapperV1.setResolverProxyVersion(_version); + } + + /** + * @notice Grants batches of RBAC roles to their configured members. + * @dev Iterates over every role/member pair and mutates access-control storage. Duplicate + * grants are handled by the access-control wrapper semantics. + * @param _rbacs Role assignments to grant. + */ + function _assignRbacRoles(IResolverProxyV1.Rbac[] memory _rbacs) internal { + for (uint256 rbacIndex; rbacIndex < _rbacs.length; ++rbacIndex) { + for (uint256 memberIndex; memberIndex < _rbacs[rbacIndex].members.length; ++memberIndex) { + AccessControlStorageWrapper.grantRole(_rbacs[rbacIndex].role, _rbacs[rbacIndex].members[memberIndex]); + } + } + } + + /** + * @notice Returns the number of facets in the active resolver-proxy configuration. + * @dev Reads the active resolver, configuration id, and version from proxy storage, then + * delegates the lookup to the business-logic resolver. + * @return facetsLength_ Number of facets registered for the active configuration version. + */ + function _getFacetsLength() internal view returns (uint256 facetsLength_) { + facetsLength_ = ResolverProxyStorageWrapperV1 + .getBusinessLogicResolver() + .getFacetsLengthByConfigurationIdAndVersion( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion() + ); + } + + /** + * @notice Returns a paginated list of facets for the active configuration version. + * @dev Performs an external view call to the configured resolver. Pagination semantics are + * defined by the resolver implementation. + * @param _pageIndex Zero-based page index. + * @param _pageLength Maximum number of facets to return. + * @return facets_ Page of facet metadata for the active configuration version. + */ + function _getFacets( + uint256 _pageIndex, + uint256 _pageLength + ) internal view returns (IDiamondLoupeV1.Facet[] memory facets_) { + facets_ = ResolverProxyStorageWrapperV1.getBusinessLogicResolver().getFacetsByConfigurationIdAndVersion( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _pageIndex, + _pageLength + ); + } + + /** + * @notice Returns the number of selectors assigned to a facet in the active configuration. + * @dev Performs an external view call to the configured resolver using the active + * configuration id and version. + * @param _facetId Facet identifier whose selector count is queried. + * @return facetSelectorsLength_ Number of selectors registered for the facet. + */ + function _getFacetSelectorsLength(bytes32 _facetId) internal view returns (uint256 facetSelectorsLength_) { + facetSelectorsLength_ = ResolverProxyStorageWrapperV1 + .getBusinessLogicResolver() + .getFacetSelectorsLengthByConfigurationIdVersionAndFacetId( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _facetId + ); + } + + /** + * @notice Returns a paginated selector list for a facet in the active configuration. + * @dev Performs an external view call to the configured resolver. Pagination semantics are + * defined by the resolver implementation. + * @param _facetId Facet identifier whose selectors are queried. + * @param _pageIndex Zero-based page index. + * @param _pageLength Maximum number of selectors to return. + * @return facetSelectors_ Page of function selectors registered for the facet. + */ + function _getFacetSelectors( + bytes32 _facetId, + uint256 _pageIndex, + uint256 _pageLength + ) internal view returns (bytes4[] memory facetSelectors_) { + facetSelectors_ = ResolverProxyStorageWrapperV1 + .getBusinessLogicResolver() + .getFacetSelectorsByConfigurationIdVersionAndFacetId( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _facetId, + _pageIndex, + _pageLength + ); + } + + /** + * @notice Returns a paginated list of facet identifiers for the active configuration version. + * @dev Performs an external view call to the configured resolver. Ordering is determined by the + * resolver implementation. + * @param _pageIndex Zero-based page index. + * @param _pageLength Maximum number of facet identifiers to return. + * @return facetIds_ Page of facet identifiers. + */ + function _getFacetIds(uint256 _pageIndex, uint256 _pageLength) internal view returns (bytes32[] memory facetIds_) { + facetIds_ = ResolverProxyStorageWrapperV1.getBusinessLogicResolver().getFacetIdsByConfigurationIdAndVersion( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _pageIndex, + _pageLength + ); + } + + /** + * @notice Returns a paginated list of facet addresses for the active configuration version. + * @dev Performs an external view call to the configured resolver. Returned addresses align with + * resolver-defined facet ordering. + * @param _pageIndex Zero-based page index. + * @param _pageLength Maximum number of facet addresses to return. + * @return facetAddresses_ Page of facet implementation addresses. + */ + function _getFacetAddresses( + uint256 _pageIndex, + uint256 _pageLength + ) internal view returns (address[] memory facetAddresses_) { + facetAddresses_ = ResolverProxyStorageWrapperV1 + .getBusinessLogicResolver() + .getFacetAddressesByConfigurationIdAndVersion( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _pageIndex, + _pageLength + ); + } + + /** + * @notice Returns the facet identifier that owns a selector in the active configuration. + * @dev Performs an external view call to the configured resolver and may return the resolver's + * default value when the selector is not registered. + * @param _selector Function selector to resolve. + * @return facetId_ Facet identifier associated with the selector. + */ + function _getFacetIdBySelector(bytes4 _selector) internal view returns (bytes32 facetId_) { + facetId_ = ResolverProxyStorageWrapperV1 + .getBusinessLogicResolver() + .getFacetIdByConfigurationIdVersionAndSelector( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _selector + ); + } + + /** + * @notice Returns facet metadata for a facet in the active configuration version. + * @dev Performs an external view call to the configured resolver. + * @param _facetId Facet identifier to query. + * @return facet_ Facet metadata registered for the identifier. + */ + function _getFacet(bytes32 _facetId) internal view returns (IDiamondLoupeV1.Facet memory facet_) { + facet_ = ResolverProxyStorageWrapperV1.getBusinessLogicResolver().getFacetByConfigurationIdVersionAndFacetId( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _facetId + ); + } + + /** + * @notice Resolves the facet implementation address for a function selector. + * @dev Uses the active resolver-proxy configuration and version. Returns the resolver's result, + * which is expected to be `address(0)` when the selector cannot be resolved. + * @param _selector Function selector to resolve. + * @return Facet implementation address selected for the selector. + */ + function _getFacetAddress(bytes4 _selector) internal view returns (address) { + return + ResolverProxyStorageWrapperV1.getBusinessLogicResolver().resolveResolverProxyCall( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _selector + ); + } + + /** + * @notice Reports whether an interface is supported by the active configuration version. + * @dev Delegates interface support resolution to the configured business-logic resolver. + * @param _interfaceId ERC-165 interface identifier to check. + * @return isSupported_ True when the active configuration supports the interface. + */ + function _supportsInterface(bytes4 _interfaceId) internal view returns (bool isSupported_) { + isSupported_ = ResolverProxyStorageWrapperV1.getBusinessLogicResolver().resolveSupportsInterface( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion(), + _interfaceId + ); + } +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyV1.sol new file mode 100644 index 0000000000..7f80538853 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/ResolverProxyV1.sol @@ -0,0 +1,74 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +/******************************************************************************\ +* Author: Nick Mudge , Twitter/Github: @mudgen +* EIP-2535 ResolverProxys +* +* Implementation of a resolverProxy. +/******************************************************************************/ + +import { ResolverProxyUnstructuredV1 } from "./ResolverProxyUnstructuredV1.sol"; +import { IResolverProxyV1 } from "./IResolverProxyV1.sol"; +import { IBusinessLogicResolverV1 } from "./IBusinessLogicResolverV1.sol"; +import { ResolverProxyStorageWrapperV1 } from "./ResolverProxyStorageWrapperV1.sol"; + +contract ResolverProxyV1 is ResolverProxyUnstructuredV1 { + /** + * @notice Deploys and initialises the resolver proxy with its resolver configuration and roles. + * @dev Validates that the requested configuration is registered before storing proxy + * configuration data and assigning RBAC roles. The constructor is payable to support + * prefunding during deployment. + * @param _resolver Business-logic resolver used to resolve selectors to facet addresses. + * @param _resolverProxyConfigurationId Configuration identifier served by this proxy. + * @param _version Configuration version pinned for selector resolution. + * @param _rbac Role assignments granted during initialisation. + */ + constructor( + IBusinessLogicResolverV1 _resolver, + bytes32 _resolverProxyConfigurationId, + uint256 _version, + IResolverProxyV1.Rbac[] memory _rbac + ) payable { + _initialize(_resolver, _resolverProxyConfigurationId, _version, _rbac); + } + + /** + * @notice Accepts native token transfers sent directly to the proxy. + * @dev Does not mutate proxy configuration or delegate execution. + */ + receive() external payable {} + + // solhint-disable-next-line no-complex-fallback + /** + * @notice Delegates calls to facet implementations. + * @dev Reverts with `FunctionNotFound` when no facet is registered. Otherwise forwards all + * calldata and remaining gas using `delegatecall`, then bubbles returned data or revert + * data unchanged to the original caller. + */ + fallback() external payable { + // get facet from function selector + address facet = _getFacetAddress(msg.sig); + if (facet == address(0)) { + revert IResolverProxyV1.FunctionNotFound(msg.sig); + } + // Execute external function from facet using delegatecall and return any value. + // solhint-disable-next-line no-inline-assembly + assembly { + // copy function selector and any arguments + calldatacopy(0, 0, calldatasize()) + // execute function call using the facet + let result := delegatecall(gas(), facet, 0, calldatasize(), 0, 0) + // get any return value + returndatacopy(0, 0, returndatasize()) + // return any return value or error back to the caller + switch result + case 0 { + revert(0, returndatasize()) + } + default { + return(0, returndatasize()) + } + } + } +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondBaseV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondBaseV1.sol new file mode 100644 index 0000000000..e776439683 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondBaseV1.sol @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { DiamondCutV1 } from "./DiamondCutV1.sol"; +import { DiamondLoupeV1 } from "./DiamondLoupeV1.sol"; +import { IDiamondFacetV1 } from "./IDiamondFacetV1.sol"; +import { RESOLVER_KEY_DIAMOND } from "../IDiamondV1.sol"; +import { InitializerStorageWrapper } from "../../../../domain/core/InitializerStorageWrapper.sol"; +import { InitializerModifiers } from "../../../../services/core/InitializerModifiers.sol"; +import { DEFAULT_ADMIN_ROLE } from "../../../../constants/roles.sol"; + +/** + * @title DiamondBase + * @author Asset Tokenization Studio Team + * @notice Abstract base for the Diamond facet that combines DiamondCut + DiamondLoupe + * with initialisation support via `initializeDiamondCut`. + * @dev Inherits from existing DiamondCut and DiamondLoupe abstracts and adds the + * initialiser function that registers the facet with the centralised + * InitializerStorageWrapper. + */ +abstract contract DiamondBaseV1 is IDiamondFacetV1, DiamondCutV1, DiamondLoupeV1, InitializerModifiers { + /// @inheritdoc IDiamondFacetV1 + function initializeDiamondCut() + external + override + onlyRole(DEFAULT_ADMIN_ROLE) + onlyFacetNotRegistered(RESOLVER_KEY_DIAMOND) + { + InitializerStorageWrapper.setFacetToReady(RESOLVER_KEY_DIAMOND); + emit DiamondCutInitialized(); + } +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondCutV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondCutV1.sol new file mode 100644 index 0000000000..48fc2af701 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondCutV1.sol @@ -0,0 +1,85 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { IDiamondCutV1 } from "./IDiamondCutV1.sol"; +import { ResolverProxyUnstructuredV1 } from "../ResolverProxyUnstructuredV1.sol"; +import { IBusinessLogicResolverV1 } from "../IBusinessLogicResolverV1.sol"; +import { DEFAULT_ADMIN_ROLE } from "../../../../constants/roles.sol"; +import { AccessControlStorageWrapper } from "../../../../domain/core/AccessControlStorageWrapper.sol"; +import { ResolverProxyStorageWrapperV1 } from "../ResolverProxyStorageWrapperV1.sol"; +import { EvmAccessors } from "../../../../infrastructure/utils/EvmAccessors.sol"; + +/** + * @title Diamond Cut + * @notice Provides privileged resolver-proxy configuration update operations. + * @dev Mutates resolver-proxy storage after validating target configurations through the + * configured or supplied business-logic resolver. Access is restricted to accounts holding + * the default admin role in the proxy access-control storage. + * @author Asset Tokenization Studio Team + */ +abstract contract DiamondCutV1 is IDiamondCutV1, ResolverProxyUnstructuredV1 { + /** + * @notice Restricts execution to accounts holding a required role. + * @dev Uses the effective EVM sender from `EvmAccessors` and reverts through access-control + * storage when the sender is not authorised. + * @param _role Role identifier required to execute the guarded function. + */ + modifier onlyRole(bytes32 _role) { + AccessControlStorageWrapper.checkRole(_role, EvmAccessors.getMsgSender()); + _; + } + + /// @inheritdoc IDiamondCutV1 + /// @dev Requires `DEFAULT_ADMIN_ROLE` and preserves the active configuration identifier and + /// resolver while updating only the pinned configuration version. + function updateConfigVersion(uint256 _newVersion) external override onlyRole(DEFAULT_ADMIN_ROLE) { + ResolverProxyStorageWrapperV1.getBusinessLogicResolver().checkResolverProxyConfigurationRegistered( + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + _newVersion + ); + _updateVersion(_newVersion); + } + + /// @inheritdoc IDiamondCutV1 + /// @dev Requires `DEFAULT_ADMIN_ROLE` and validates the configuration before storing the new + /// configuration identifier and pinned version. + function updateConfig( + bytes32 _newConfigurationId, + uint256 _newVersion + ) external override onlyRole(DEFAULT_ADMIN_ROLE) { + ResolverProxyStorageWrapperV1.getBusinessLogicResolver().checkResolverProxyConfigurationRegistered( + _newConfigurationId, + _newVersion + ); + _updateConfigId(_newConfigurationId); + _updateVersion(_newVersion); + } + + /// @inheritdoc IDiamondCutV1 + /// @dev Requires `DEFAULT_ADMIN_ROLE` and validates the target configuration against the new + /// resolver before replacing the resolver pointer, configuration identifier and version. + function updateResolver( + IBusinessLogicResolverV1 _newResolver, + bytes32 _newConfigurationId, + uint256 _newVersion + ) external override onlyRole(DEFAULT_ADMIN_ROLE) { + _newResolver.checkResolverProxyConfigurationRegistered(_newConfigurationId, _newVersion); + _updateResolver(_newResolver); + _updateConfigId(_newConfigurationId); + _updateVersion(_newVersion); + } + + /// @inheritdoc IDiamondCutV1 + function getConfigInfo() + external + view + override + returns (address resolver_, bytes32 configurationId_, uint256 version_) + { + return ( + address(ResolverProxyStorageWrapperV1.getBusinessLogicResolver()), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationId(), + ResolverProxyStorageWrapperV1.getResolverProxyConfigurationVersion() + ); + } +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondLoupeV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondLoupeV1.sol new file mode 100644 index 0000000000..fa593b7a23 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/DiamondLoupeV1.sol @@ -0,0 +1,106 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +// The functions in DiamondLoupeFacet.sol.sol MUST be added to a resolverProxy. +// The EIP-2535 ResolverProxy standard requires these functions. +import { ResolverProxyUnstructuredV1 } from "../ResolverProxyUnstructuredV1.sol"; +import { IDiamondLoupeV1 } from "../IDiamondLoupeV1.sol"; +import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol"; + +/** + * @title Diamond Loupe + * @notice Exposes read-only introspection helpers for resolver-proxy facet metadata. + * @dev Implements the EIP-2535 loupe view surface over resolver-proxy storage. All queries are + * read-only and delegate pagination, selector, facet and ERC-165 lookups to inherited + * storage helpers. + * @author Asset Tokenization Studio Team + */ +abstract contract DiamondLoupeV1 is IDiamondLoupeV1, IERC165, ResolverProxyUnstructuredV1 { + /// @inheritdoc IDiamondLoupeV1 + function getFacets() external view override returns (Facet[] memory facets_) { + facets_ = _getFacets(0, _getFacetsLength()); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetsLength() external view override returns (uint256 facetsLength_) { + facetsLength_ = _getFacetsLength(); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetsByPage( + uint256 _pageIndex, + uint256 _pageLength + ) external view override returns (Facet[] memory facets_) { + facets_ = _getFacets(_pageIndex, _pageLength); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetSelectors(bytes32 _facetId) external view override returns (bytes4[] memory facetSelectors_) { + facetSelectors_ = _getFacetSelectors(_facetId, 0, _getFacetSelectorsLength(_facetId)); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetSelectorsLength(bytes32 _facetId) external view override returns (uint256 facetSelectorsLength_) { + facetSelectorsLength_ = _getFacetSelectorsLength(_facetId); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetSelectorsByPage( + bytes32 _facetId, + uint256 _pageIndex, + uint256 _pageLength + ) external view override returns (bytes4[] memory facetSelectors_) { + facetSelectors_ = _getFacetSelectors(_facetId, _pageIndex, _pageLength); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetIds() external view override returns (bytes32[] memory facetIds_) { + facetIds_ = _getFacetIds(0, _getFacetsLength()); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetIdsByPage( + uint256 _pageIndex, + uint256 _pageLength + ) external view override returns (bytes32[] memory facetIds_) { + facetIds_ = _getFacetIds(_pageIndex, _pageLength); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetAddresses() external view override returns (address[] memory facetAddresses_) { + facetAddresses_ = _getFacetAddresses(0, _getFacetsLength()); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetAddressesByPage( + uint256 _pageIndex, + uint256 _pageLength + ) external view override returns (address[] memory facetAddresses_) { + facetAddresses_ = _getFacetAddresses(_pageIndex, _pageLength); + } + + /** + * @notice Returns the facet identifier registered for a function selector. + * @dev Reads resolver-proxy selector metadata and returns zero when the selector is absent. + * @param _selector Function selector to resolve. + * @return facetId_ Facet identifier associated with the selector. + */ + function getFacetIdBySelector(bytes4 _selector) external view returns (bytes32 facetId_) { + facetId_ = _getFacetIdBySelector(_selector); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacet(bytes32 _facetId) external view override returns (Facet memory facet_) { + facet_ = _getFacet(_facetId); + } + + /// @inheritdoc IDiamondLoupeV1 + function getFacetAddress(bytes4 _selector) external view override returns (address facetAddress_) { + facetAddress_ = _getFacetAddress(_selector); + } + + /// @inheritdoc IERC165 + function supportsInterface(bytes4 _interfaceId) external view override returns (bool) { + return _supportsInterface(_interfaceId); + } +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/IDiamondCutV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/IDiamondCutV1.sol new file mode 100644 index 0000000000..7edca0debc --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/IDiamondCutV1.sol @@ -0,0 +1,44 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +import { IStaticFunctionSelectorsV1 } from "../IStaticFunctionSelectorsV1.sol"; +import { IBusinessLogicResolverV1 } from "../IBusinessLogicResolverV1.sol"; + +/// @title IDiamondCut +/// @author Asset Tokenization Studio Team +/// @notice Interface for upgrading the Diamond proxy's Business Logic Resolver (BLR), +/// configuration identifier, and version in a single or multi-step operation. +interface IDiamondCutV1 is IStaticFunctionSelectorsV1 { + /** + * @notice For the current BLR and configuration, update the used version. + * @param _newVersion The new version number to set for the current configuration. + */ + function updateConfigVersion(uint256 _newVersion) external; + + /** + * @notice For the current BLR, update its configuration identifier and version. + * @param _newConfigurationId The new configuration identifier to apply. + * @param _newVersion The version number associated with the new configuration. + */ + function updateConfig(bytes32 _newConfigurationId, uint256 _newVersion) external; + + /** + * @notice Replaces the Business Logic Resolver with a new one, setting configuration and version. + * @param _newResolver The new BLR contract address to wire into the proxy. + * @param _newConfigurationId The configuration identifier to activate on the new resolver. + * @param _newVersion The version number associated with the new configuration. + */ + function updateResolver( + IBusinessLogicResolverV1 _newResolver, + bytes32 _newConfigurationId, + uint256 _newVersion + ) external; + + /** + * @notice Returns the active resolver address, configuration identifier, and version. + * @return resolver_ Address of the current Business Logic Resolver. + * @return configurationId_ Identifier of the active configuration. + * @return version_ Version number of the active configuration. + */ + function getConfigInfo() external view returns (address resolver_, bytes32 configurationId_, uint256 version_); +} diff --git a/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/IDiamondFacetV1.sol b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/IDiamondFacetV1.sol new file mode 100644 index 0000000000..22eeb2e321 --- /dev/null +++ b/packages/ats/contracts/contracts/test/mocks/resolverProxyV1/diamondFacet/IDiamondFacetV1.sol @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: Apache-2.0 +pragma solidity >=0.8.0 <0.9.0; + +/** + * @title IDiamondFacetV1 + * @author Asset Tokenization Studio Team + * @notice Interface for the Diamond facet initialisation function. + * @dev Separated from IDiamond (EIP-2535 standard) so the standard interface + * remains unmodified. + */ +interface IDiamondFacetV1 { + /** + * @notice Emitted once when the diamond facet is initialised. + * @dev Fires exclusively from `initializeDiamondCut`. + */ + event DiamondCutInitialized(); + + /** + * @notice Initialises the diamond facet and registers it in the initialiser registry. + * @dev Callable once; subsequent calls revert with `FacetAlreadyRegistered`. + * Requires `DEFAULT_ADMIN_ROLE`. Called by the factory during deployment. + */ + function initializeDiamondCut() external; +} diff --git a/packages/ats/contracts/package.json b/packages/ats/contracts/package.json index 269fe990cf..6cbc3d0d55 100644 --- a/packages/ats/contracts/package.json +++ b/packages/ats/contracts/package.json @@ -1,6 +1,6 @@ { "name": "@hashgraph/asset-tokenization-contracts", - "version": "8.0.0", + "version": "8.0.1", "repository": "https://github.com/hashgraph/asset-tokenization-studio", "type": "commonjs", "main": "./build/typechain-types/index.js", diff --git a/packages/ats/contracts/scripts/domain/factory/deploy.ts b/packages/ats/contracts/scripts/domain/factory/deploy.ts index 1fb574fdc9..3842d6ecd0 100644 --- a/packages/ats/contracts/scripts/domain/factory/deploy.ts +++ b/packages/ats/contracts/scripts/domain/factory/deploy.ts @@ -97,8 +97,7 @@ export async function deployFactory(signer: Signer, options: DeployFactoryOption const resolverProxyFactory = new ResolverProxy__factory(signer); const factoryProxy = await resolverProxyFactory.deploy( blrAddress, - FACTORY_CONFIG_ID, - factoryVersion, + { configurationId: FACTORY_CONFIG_ID, configurationVersion: factoryVersion, replacementEnabled: true }, [], // empty rbacs — Factory is permissionless in v1 { ...gasLimitOverride(GAS_LIMIT.high), diff --git a/packages/ats/contracts/scripts/domain/factory/deployBondFixedRateToken.ts b/packages/ats/contracts/scripts/domain/factory/deployBondFixedRateToken.ts index 273b904d61..82b63bb5e1 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployBondFixedRateToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployBondFixedRateToken.ts @@ -79,9 +79,10 @@ export async function deployBondFixedRateFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = { - key: BOND_FIXED_RATE_CONFIG_ID, - version: 1, + const resolverProxyConfigurationV2 = { + configurationId: BOND_FIXED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; // Build security data structure @@ -89,7 +90,7 @@ export async function deployBondFixedRateFromFactory( arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, diff --git a/packages/ats/contracts/scripts/domain/factory/deployBondKpiLinkedRateToken.ts b/packages/ats/contracts/scripts/domain/factory/deployBondKpiLinkedRateToken.ts index b69fbc271d..3101311733 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployBondKpiLinkedRateToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployBondKpiLinkedRateToken.ts @@ -92,9 +92,10 @@ export async function deployBondKpiLinkedRateFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + const resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; // Build security data structure @@ -102,7 +103,7 @@ export async function deployBondKpiLinkedRateFromFactory( arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, diff --git a/packages/ats/contracts/scripts/domain/factory/deployBondToken.ts b/packages/ats/contracts/scripts/domain/factory/deployBondToken.ts index 1c23db4242..c8c9b5ad8c 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployBondToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployBondToken.ts @@ -79,9 +79,10 @@ export async function deployBondFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + const resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; // Build security data structure @@ -89,7 +90,7 @@ export async function deployBondFromFactory( arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, diff --git a/packages/ats/contracts/scripts/domain/factory/deployDepositToken.ts b/packages/ats/contracts/scripts/domain/factory/deployDepositToken.ts index 1ca0991928..a2d89a9b5e 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployDepositToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployDepositToken.ts @@ -62,9 +62,10 @@ export async function deployDepositTokenFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = { - key: DEPOSIT_TOKEN_CONFIG_ID, - version: 1, + const resolverProxyConfigurationV2 = { + configurationId: DEPOSIT_TOKEN_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; // Build security data structure @@ -72,7 +73,7 @@ export async function deployDepositTokenFromFactory( arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, diff --git a/packages/ats/contracts/scripts/domain/factory/deployEquityToken.ts b/packages/ats/contracts/scripts/domain/factory/deployEquityToken.ts index 94b9749f5f..5d79cc5ba3 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployEquityToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployEquityToken.ts @@ -70,9 +70,10 @@ export async function deployEquityFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + const resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; // Build security data structure @@ -80,7 +81,7 @@ export async function deployEquityFromFactory( arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, diff --git a/packages/ats/contracts/scripts/domain/factory/deployLoanToken.ts b/packages/ats/contracts/scripts/domain/factory/deployLoanToken.ts index 80e736b81c..376d5290ae 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployLoanToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployLoanToken.ts @@ -56,14 +56,14 @@ export async function deployLoanFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = securityDataParams.resolverProxyConfiguration; + const resolverProxyConfigurationV2 = securityDataParams.resolverProxyConfigurationV2; // Build security data structure const securityData = { arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, @@ -84,16 +84,9 @@ export async function deployLoanFromFactory( }; // Deploy loan token via factory using deployProxy (generic proxy deployer) - const tx = await factory.deployProxy( - securityData.resolver, - resolverProxyConfiguration.key, - resolverProxyConfiguration.version, - rbacs, - "0x", - { - gasLimit: GAS_LIMIT.high, - }, - ); + const tx = await factory.deployProxy(securityData.resolver, resolverProxyConfigurationV2, rbacs, "0x", { + gasLimit: GAS_LIMIT.high, + }); const receipt = await tx.wait(); // Find ProxyDeployed event to get diamond address diff --git a/packages/ats/contracts/scripts/domain/factory/deployLoansPortfolioToken.ts b/packages/ats/contracts/scripts/domain/factory/deployLoansPortfolioToken.ts index 45ff632af7..22c495036f 100644 --- a/packages/ats/contracts/scripts/domain/factory/deployLoansPortfolioToken.ts +++ b/packages/ats/contracts/scripts/domain/factory/deployLoansPortfolioToken.ts @@ -56,9 +56,10 @@ export async function deployLoansPortfolioFromFactory( ]; // Build resolver proxy configuration - const resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + const resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; // Build security data structure @@ -66,7 +67,7 @@ export async function deployLoansPortfolioFromFactory( arePartitionsProtected: securityDataParams.arePartitionsProtected, isMultiPartition: securityDataParams.isMultiPartition, resolver: securityDataParams.resolver, - resolverProxyConfiguration, + resolverProxyConfigurationV2, rbacs, isControllable: securityDataParams.isControllable, isWhiteList: securityDataParams.isWhiteList, @@ -87,16 +88,9 @@ export async function deployLoansPortfolioFromFactory( }; // Deploy loans portfolio token via factory using deployProxy (generic proxy deployer) - const tx = await factory.deployProxy( - securityData.resolver, - resolverProxyConfiguration.key, - resolverProxyConfiguration.version, - rbacs, - "0x", - { - gasLimit: GAS_LIMIT.high, - }, - ); + const tx = await factory.deployProxy(securityData.resolver, resolverProxyConfigurationV2, rbacs, "0x", { + gasLimit: GAS_LIMIT.high, + }); const receipt = await tx.wait(); // Find ProxyDeployed event to get diamond address diff --git a/packages/ats/contracts/scripts/domain/factory/types.ts b/packages/ats/contracts/scripts/domain/factory/types.ts index 593b01cc83..4c4e0007f7 100644 --- a/packages/ats/contracts/scripts/domain/factory/types.ts +++ b/packages/ats/contracts/scripts/domain/factory/types.ts @@ -45,9 +45,10 @@ export interface SecurityDataParams { compliance: string; /** Identity registry contract address */ identityRegistry: string; - resolverProxyConfiguration: { - key: string; - version: number; + resolverProxyConfigurationV2: { + configurationId: string; + configurationVersion: number; + replacementEnabled: boolean; }; /** RBAC roles and their assigned addresses */ rbacs: Rbac[]; diff --git a/packages/ats/contracts/scripts/infrastructure/operations/deployResolverProxy.ts b/packages/ats/contracts/scripts/infrastructure/operations/deployResolverProxy.ts index 2578f4a71d..86962cc688 100644 --- a/packages/ats/contracts/scripts/infrastructure/operations/deployResolverProxy.ts +++ b/packages/ats/contracts/scripts/infrastructure/operations/deployResolverProxy.ts @@ -178,8 +178,11 @@ export async function deployResolverProxy( info("Deploying ResolverProxy contract..."); const resolverProxy = await ResolverProxyFactory.deploy( blrAddress, - configurationId, - version, + { + configurationId, + configurationVersion: version, + replacementEnabled: false, + }, rbac, overrides as any, ); diff --git a/packages/ats/contracts/scripts/infrastructure/operations/updateResolverProxyConfig.ts b/packages/ats/contracts/scripts/infrastructure/operations/updateResolverProxyConfig.ts index cca7dc5986..7fa056b5cb 100644 --- a/packages/ats/contracts/scripts/infrastructure/operations/updateResolverProxyConfig.ts +++ b/packages/ats/contracts/scripts/infrastructure/operations/updateResolverProxyConfig.ts @@ -67,6 +67,8 @@ interface InternalUpdateOptions { newVersion: number; /** New configuration ID (required for 'config' and 'resolver' types) */ newConfigurationId?: string; + /** New replacement enabled flag (required for 'config' and 'resolver' types) */ + newReplacementEnabled?: boolean; /** New BLR address (required for 'resolver' type) */ newBlrAddress?: string; /** Transaction overrides */ @@ -82,11 +84,15 @@ export interface ResolverProxyConfigInfo { /** Current BusinessLogicResolver address */ resolver: string; + version: number; + /** Current configuration ID */ configurationId: string; /** Current version */ - version: number; + configurationVersion: number; + + replacementEnabled: boolean; } /** @@ -155,12 +161,15 @@ export async function getResolverProxyConfigInfo( validateAddress(proxyAddress, "ResolverProxy address"); const diamondCutFacet = DiamondFacet__factory.connect(proxyAddress, signerOrProvider); - const [resolver, configId, version] = await diamondCutFacet.getConfigInfo(); + const [resolver, version, configId, configurationVersion, replacementEnabled] = + await diamondCutFacet.getConfigInfo(); return { resolver, - configurationId: configId, version: Number(version), + configurationId: configId, + configurationVersion: Number(configurationVersion), + replacementEnabled: replacementEnabled, }; } catch (err) { const errorMessage = extractRevertReason(err); @@ -342,6 +351,7 @@ async function _updateResolverProxyInternal( updateType, newVersion, newConfigurationId, + newReplacementEnabled, newBlrAddress, overrides = {}, confirmations, @@ -370,7 +380,7 @@ async function _updateResolverProxyInternal( info("Fetching current configuration..."); const previousConfig = await getResolverProxyConfigInfo(signer, proxyAddress); debug( - `Previous config: resolver=${previousConfig.resolver}, configId=${previousConfig.configurationId}, version=${previousConfig.version}`, + `Previous config: resolver=${previousConfig.resolver}, configId=${previousConfig.configurationId}, version=${previousConfig.configurationVersion}`, ); const diamondCutFacet = DiamondFacet__factory.connect(proxyAddress, signer); @@ -382,7 +392,13 @@ async function _updateResolverProxyInternal( switch (updateType) { case "resolver": debug("Calling updateResolver()"); - updateTx = await diamondCutFacet.updateResolver(newBlrAddress!, newConfigurationId!, newVersion, overrides); + updateTx = await diamondCutFacet.updateResolver( + newBlrAddress!, + newConfigurationId!, + newVersion, + newReplacementEnabled ?? false, + overrides, + ); break; case "config": debug("Calling updateConfig()"); @@ -431,7 +447,7 @@ async function _updateResolverProxyInternal( try { newConfig = await getResolverProxyConfigInfo(signer, proxyAddress); debug( - `New config: resolver=${newConfig.resolver}, configId=${newConfig.configurationId}, version=${newConfig.version}`, + `New config: resolver=${newConfig.resolver}, configId=${newConfig.configurationId}, version=${newConfig.configurationVersion}`, ); } catch (configErr) { const errorMessage = extractRevertReason(configErr); @@ -450,8 +466,8 @@ async function _updateResolverProxyInternal( } success("ResolverProxy configuration updated successfully"); - info(` Previous version: ${previousConfig.version}`); - info(` New version: ${newConfig.version}`); + info(` Previous version: ${previousConfig.configurationVersion}`); + info(` New version: ${newConfig.configurationVersion}`); if (previousConfig.configurationId !== newConfig.configurationId) { info(` Previous config ID: ${previousConfig.configurationId}`); info(` New config ID: ${newConfig.configurationId}`); diff --git a/packages/ats/contracts/scripts/workflows/upgradeConfigurations.ts b/packages/ats/contracts/scripts/workflows/upgradeConfigurations.ts index 412f4c1418..2f26a6147f 100644 --- a/packages/ats/contracts/scripts/workflows/upgradeConfigurations.ts +++ b/packages/ats/contracts/scripts/workflows/upgradeConfigurations.ts @@ -829,7 +829,7 @@ async function updateProxiesPhase(ctx: UpgradePhaseContext): Promise AssetMockCtx): void { const verifyingContract = await asset.getAddress(); const domain = { name: (await asset.getERC20Metadata()).info.name, - version: (await asset.getConfigInfo()).version_.toString(), + version: (await asset.getConfigInfo()).configurationVersion_.toString(), chainId: await network.provider.send("eth_chainId"), verifyingContract, }; diff --git a/packages/ats/contracts/test/contracts/integration/clearingByPartition/clearingByPartition.test.ts b/packages/ats/contracts/test/contracts/integration/clearingByPartition/clearingByPartition.test.ts index d4299f698a..90c65e4bd1 100644 --- a/packages/ats/contracts/test/contracts/integration/clearingByPartition/clearingByPartition.test.ts +++ b/packages/ats/contracts/test/contracts/integration/clearingByPartition/clearingByPartition.test.ts @@ -1296,7 +1296,7 @@ export function clearingByPartitionTests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { @@ -1669,7 +1669,7 @@ export function clearingByPartitionTests(getCtx: () => AssetMockCtx): void { }; const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { diff --git a/packages/ats/contracts/test/contracts/integration/clearingHoldByPartition/clearingHoldByPartition.test.ts b/packages/ats/contracts/test/contracts/integration/clearingHoldByPartition/clearingHoldByPartition.test.ts index 450f4d7985..2066a1382d 100644 --- a/packages/ats/contracts/test/contracts/integration/clearingHoldByPartition/clearingHoldByPartition.test.ts +++ b/packages/ats/contracts/test/contracts/integration/clearingHoldByPartition/clearingHoldByPartition.test.ts @@ -595,7 +595,7 @@ export function clearingHoldByPartitionTests(getCtx: () => AssetMockCtx): void { // EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { diff --git a/packages/ats/contracts/test/contracts/integration/core/core.test.ts b/packages/ats/contracts/test/contracts/integration/core/core.test.ts index 5a7989f0c2..5827756e50 100644 --- a/packages/ats/contracts/test/contracts/integration/core/core.test.ts +++ b/packages/ats/contracts/test/contracts/integration/core/core.test.ts @@ -90,7 +90,7 @@ export function coreTests(getCtx: () => AssetMockCtx): void { it("GIVEN an initialized token WHEN reading version THEN returns a JSON string matching the BLR config", async () => { const json = await asset.version(); const parsed = JSON.parse(json); - const [configResolver, configId, configVersion] = await asset.getConfigInfo(); + const [configResolver, , configId, configVersion] = await asset.getConfigInfo(); expect(parsed["Resolver"].toLowerCase()).to.equal(configResolver.toLowerCase()); expect(parsed["Config ID"].toLowerCase()).to.equal(configId.toLowerCase()); diff --git a/packages/ats/contracts/test/contracts/integration/eip712/eip712.test.ts b/packages/ats/contracts/test/contracts/integration/eip712/eip712.test.ts index 46811d3757..268cdc3da9 100644 --- a/packages/ats/contracts/test/contracts/integration/eip712/eip712.test.ts +++ b/packages/ats/contracts/test/contracts/integration/eip712/eip712.test.ts @@ -24,7 +24,7 @@ export function eip712Tests(getCtx: () => AssetMockCtx): void { it("GIVEN a deployed contract WHEN DOMAIN_SEPARATOR is called THEN the correct domain separator is returned", async () => { const domainSeparator = await asset.DOMAIN_SEPARATOR(); const CONTRACT_NAME = (await asset.getERC20Metadata()).info.name; - const CONTRACT_VERSION = (await asset.getConfigInfo()).version_.toString(); + const CONTRACT_VERSION = (await asset.getConfigInfo()).configurationVersion_.toString(); const domain = { name: CONTRACT_NAME, version: CONTRACT_VERSION, diff --git a/packages/ats/contracts/test/contracts/integration/factory/factory.test.ts b/packages/ats/contracts/test/contracts/integration/factory/factory.test.ts index b8a09f001e..2418fd1a05 100644 --- a/packages/ats/contracts/test/contracts/integration/factory/factory.test.ts +++ b/packages/ats/contracts/test/contracts/integration/factory/factory.test.ts @@ -102,9 +102,10 @@ describe("Factory Tests", () => { equityDetails: makeEquityDetailsData(), }; equityData.security.resolver = ADDRESS_ZERO; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployEquity(equityData, getRegulationData())).to.be.revertedWithCustomError( @@ -123,9 +124,10 @@ describe("Factory Tests", () => { proceedRecipientsData: [], }; bondData.security.resolver = ADDRESS_ZERO; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBond(bondData, getRegulationData())).to.be.revertedWithCustomError( @@ -141,9 +143,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployEquity(equityData, getRegulationData())).to.emit(factory, "EquityDeployed"); @@ -165,9 +168,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployEquity(equityData, getRegulationData())).to.be.revertedWithCustomError( @@ -192,9 +196,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBond(bondData, getRegulationData())).to.be.revertedWithCustomError( @@ -217,9 +222,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployEquity(equityData, getRegulationData())).to.be.revertedWithCustomError( @@ -242,9 +248,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployEquity(equityData, getRegulationData())).to.emit(factory, "EquityDeployed"); @@ -270,9 +277,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBond(bondData, getRegulationData())).to.emit(factory, "BondDeployed"); @@ -287,9 +295,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const invalidRegulationData = getRegulationData({ @@ -311,9 +320,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const invalidRegulationData = getRegulationData({ @@ -333,9 +343,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const invalidRegulationData = getRegulationData({ @@ -355,9 +366,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const validRegulationData = getRegulationData({ @@ -377,9 +389,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const regSRegulationData = getRegulationData({ @@ -394,24 +407,39 @@ describe("Factory Tests", () => { describe("Generic Proxy tests", () => { it("GIVEN an empty Resolver WHEN deploying a new resolverProxy THEN transaction fails", async () => { + const resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, + }; await expect( - factory.deployProxy(ADDRESS_ZERO, EQUITY_CONFIG_ID, 1, init_rbacs, "0x"), + factory.deployProxy(ADDRESS_ZERO, resolverProxyConfigurationV2, init_rbacs, "0x"), ).to.be.revertedWithCustomError(factory, "EmptyResolver"); }); it("GIVEN no admin WHEN deploying a new resolverProxy THEN transaction fails", async () => { + const resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, + }; await expect( - factory.deployProxy(businessLogicResolver, EQUITY_CONFIG_ID, 1, [], "0x"), + factory.deployProxy(businessLogicResolver, resolverProxyConfigurationV2, [], "0x"), ).to.be.revertedWithCustomError(factory, "NoInitialAdmins"); }); it("GIVEN the proper information WHEN deploying a new resolverProxy THEN transaction succeeds", async () => { const originalData = "0x1234567812345678"; + const resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, + }; const expectedProxyAddress = await factory .getFunction("deployProxy") - .staticCall(businessLogicResolver, EQUITY_CONFIG_ID, 1, init_rbacs, originalData); + .staticCall(businessLogicResolver, resolverProxyConfigurationV2, init_rbacs, originalData); - const tx = factory.deployProxy(businessLogicResolver, EQUITY_CONFIG_ID, 1, init_rbacs, originalData); + const tx = factory.deployProxy(businessLogicResolver, resolverProxyConfigurationV2, init_rbacs, originalData); await expect(tx).to.emit(factory, "ProxyDeployed"); const result = await tx; @@ -449,9 +477,10 @@ describe("Factory Tests", () => { security: getSecurityData(businessLogicResolver), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; equityData.security.resolver = ADDRESS_ZERO; @@ -468,9 +497,10 @@ describe("Factory Tests", () => { security: getSecurityData(businessLogicResolver), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -488,9 +518,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData({ @@ -515,9 +546,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData({ @@ -542,9 +574,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -601,9 +634,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; bondData.security.resolver = ADDRESS_ZERO; @@ -622,9 +656,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -646,9 +681,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -677,9 +713,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -744,9 +781,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData({ @@ -773,9 +811,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData({ @@ -801,7 +840,7 @@ describe("Factory Tests", () => { return { security: getSecurityData(businessLogicResolver, { rbacs: init_rbacs, - resolverProxyConfiguration: { key: DEPOSIT_TOKEN_CONFIG_ID, version: 1 }, + resolverProxyConfigurationV2: { configurationId: DEPOSIT_TOKEN_CONFIG_ID, configurationVersion: 1 }, }), }; } @@ -931,9 +970,10 @@ describe("Factory Tests", () => { }, }; - bondFixedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_FIXED_RATE_CONFIG_ID, - version: 1, + bondFixedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_FIXED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const tx = factory.deployBondFixedRate(bondFixedRateData); @@ -969,9 +1009,10 @@ describe("Factory Tests", () => { }; bondFixedRateData.bondData.security.resolver = ADDRESS_ZERO; - bondFixedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_FIXED_RATE_CONFIG_ID, - version: 1, + bondFixedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_FIXED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondFixedRate(bondFixedRateData)).to.be.revertedWithCustomError( @@ -995,9 +1036,10 @@ describe("Factory Tests", () => { }, }; - bondFixedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_FIXED_RATE_CONFIG_ID, - version: 1, + bondFixedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_FIXED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondFixedRate(bondFixedRateData)).to.be.revertedWithCustomError( @@ -1026,9 +1068,10 @@ describe("Factory Tests", () => { }, }; - bondFixedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_FIXED_RATE_CONFIG_ID, - version: 1, + bondFixedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_FIXED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondFixedRate(bondFixedRateData)) @@ -1068,9 +1111,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const tx = factory.deployBondKpiLinkedRate(bondKpiLinkedRateData); @@ -1124,9 +1168,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1165,9 +1210,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1206,9 +1252,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1247,9 +1294,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1288,9 +1336,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1329,9 +1378,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1371,9 +1421,10 @@ describe("Factory Tests", () => { }; bondKpiLinkedRateData.bondData.security.resolver = ADDRESS_ZERO; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1410,9 +1461,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)).to.be.revertedWithCustomError( @@ -1454,9 +1506,10 @@ describe("Factory Tests", () => { }, }; - bondKpiLinkedRateData.bondData.security.resolverProxyConfiguration = { - key: BOND_KPI_LINKED_RATE_CONFIG_ID, - version: 1, + bondKpiLinkedRateData.bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_KPI_LINKED_RATE_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; await expect(factory.deployBondKpiLinkedRate(bondKpiLinkedRateData)) @@ -1480,9 +1533,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -1507,9 +1561,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -1538,9 +1593,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -1565,9 +1621,10 @@ describe("Factory Tests", () => { }), equityDetails: makeEquityDetailsData(), }; - equityData.security.resolverProxyConfiguration = { - key: EQUITY_CONFIG_ID, - version: 1, + equityData.security.resolverProxyConfigurationV2 = { + configurationId: EQUITY_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); @@ -1599,9 +1656,10 @@ describe("Factory Tests", () => { proceedRecipients: [], proceedRecipientsData: [], }; - bondData.security.resolverProxyConfiguration = { - key: BOND_CONFIG_ID, - version: 1, + bondData.security.resolverProxyConfigurationV2 = { + configurationId: BOND_CONFIG_ID, + configurationVersion: 1, + replacementEnabled: true, }; const factoryRegulationData = getRegulationData(); diff --git a/packages/ats/contracts/test/contracts/integration/initializer/initializer.test.ts b/packages/ats/contracts/test/contracts/integration/initializer/initializer.test.ts index f6c4bdf303..4f7ad8c706 100644 --- a/packages/ats/contracts/test/contracts/integration/initializer/initializer.test.ts +++ b/packages/ats/contracts/test/contracts/integration/initializer/initializer.test.ts @@ -130,7 +130,12 @@ describe("Initializer — InitializeMock domain", () => { // Each test gets its own proxy so initializer state never leaks between them. const deployMockAsset = async (version: number) => { const rbacs = [{ role: ATS_ROLES.DEFAULT_ADMIN_ROLE, members: [deployer.address] }]; - const tx = await factory.deployProxy(blrAddress, INITIALIZE_MOCK_CONFIG_ID, version, rbacs, "0x"); + const tx = await factory.deployProxy( + blrAddress, + { configurationId: INITIALIZE_MOCK_CONFIG_ID, configurationVersion: version, replacementEnabled: false }, + rbacs, + "0x", + ); const receipt = await tx.wait(); const proxyAddress = (await decodeEvent(factory, "ProxyDeployed", receipt!)).proxyAddress as string; @@ -595,8 +600,7 @@ describe("Initializer — InitializeMock domain", () => { const infra = await loadFixture(deployAtsInfrastructureFixture); const proxyTx = await infra.factory.deployProxy( infra.blr.target as string, - EQUITY_CONFIG_ID, - 1, + { configurationId: EQUITY_CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, [{ role: ATS_ROLES.DEFAULT_ADMIN_ROLE, members: [infra.deployer.address] }], "0x", ); @@ -613,8 +617,7 @@ describe("Initializer — InitializeMock domain", () => { const infra = await loadFixture(deployAtsInfrastructureFixture); const proxyTx = await infra.factory.deployProxy( infra.blr.target as string, - EQUITY_CONFIG_ID, - 1, + { configurationId: EQUITY_CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, [{ role: ATS_ROLES.DEFAULT_ADMIN_ROLE, members: [infra.deployer.address] }], "0x", ); @@ -634,8 +637,7 @@ describe("Initializer — InitializeMock domain", () => { const infra = await loadFixture(deployAtsInfrastructureFixture); const proxyTx = await infra.factory.deployProxy( infra.blr.target as string, - EQUITY_CONFIG_ID, - 1, + { configurationId: EQUITY_CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, [{ role: ATS_ROLES.DEFAULT_ADMIN_ROLE, members: [infra.deployer.address] }], "0x", ); diff --git a/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC1410/erc1410.test.ts b/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC1410/erc1410.test.ts index 7b24c8ee41..343ff8db49 100644 --- a/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC1410/erc1410.test.ts +++ b/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC1410/erc1410.test.ts @@ -3489,7 +3489,7 @@ export function erc1410Tests(getCtx: () => AssetMockCtx): void { it("GIVEN valid signature WHEN protectedTransferFromByPartition THEN transaction succeeds and emits Transfer", async () => { const domainSeparator = { name: (await asset.getERC20Metadata()).info.name, - version: (await asset.getConfigInfo()).version_.toString(), + version: (await asset.getConfigInfo()).configurationVersion_.toString(), chainId: await network.provider.send("eth_chainId"), verifyingContract: asset.target as string, }; @@ -3898,7 +3898,7 @@ export function erc1410Tests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { @@ -3988,7 +3988,7 @@ export function erc1410Tests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { @@ -4084,7 +4084,7 @@ export function erc1410Tests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { diff --git a/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC20Permit/erc20Permit.test.ts b/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC20Permit/erc20Permit.test.ts index 1f0d417e21..8b9f3a37e1 100644 --- a/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC20Permit/erc20Permit.test.ts +++ b/packages/ats/contracts/test/contracts/integration/layer_1/ERC1400/ERC20Permit/erc20Permit.test.ts @@ -144,7 +144,7 @@ export function erc20PermitTests(getCtx: () => AssetMockCtx): void { const nonce = await asset.nonces(signer_A.address); const expiry = (await getDltTimestamp()) + 3600; const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const verifyingContract = await asset.getAddress(); const domain = { @@ -184,7 +184,7 @@ export function erc20PermitTests(getCtx: () => AssetMockCtx): void { const nonce = await asset.nonces(signer_A.address); const expiry = (await getDltTimestamp()) + 3600; const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const verifyingContract = await asset.getAddress(); const domain = { diff --git a/packages/ats/contracts/test/contracts/integration/layer_1/ERC3643/erc3643.test.ts b/packages/ats/contracts/test/contracts/integration/layer_1/ERC3643/erc3643.test.ts index 1ca1ab0abb..40fc9966f2 100644 --- a/packages/ats/contracts/test/contracts/integration/layer_1/ERC3643/erc3643.test.ts +++ b/packages/ats/contracts/test/contracts/integration/layer_1/ERC3643/erc3643.test.ts @@ -128,7 +128,7 @@ export function erc3643Tests(getCtx: () => AssetMockCtx): void { const json = await asset.version(); const parsed = JSON.parse(json); - const [configResolver, configId, configVersion] = await asset.getConfigInfo(); + const [configResolver, , configId, configVersion] = await asset.getConfigInfo(); expect(parsed["Resolver"].toLowerCase()).to.equal(configResolver.toLowerCase()); expect(parsed["Config ID"].toLowerCase()).to.equal(configId.toLowerCase()); diff --git a/packages/ats/contracts/test/contracts/integration/layer_1/clearing/clearing.test.ts b/packages/ats/contracts/test/contracts/integration/layer_1/clearing/clearing.test.ts index 5a2d281002..e262a9f1e3 100644 --- a/packages/ats/contracts/test/contracts/integration/layer_1/clearing/clearing.test.ts +++ b/packages/ats/contracts/test/contracts/integration/layer_1/clearing/clearing.test.ts @@ -4013,7 +4013,7 @@ export function clearingTests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { @@ -4103,7 +4103,7 @@ export function clearingTests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { @@ -4199,7 +4199,7 @@ export function clearingTests(getCtx: () => AssetMockCtx): void { // Prepare EIP-712 domain const name = (await asset.getERC20Metadata()).info.name; - const version = (await asset.getConfigInfo()).version_.toString(); + const version = (await asset.getConfigInfo()).configurationVersion_.toString(); const chainId = await network.provider.send("eth_chainId"); const domain = { diff --git a/packages/ats/contracts/test/contracts/integration/layer_1/protectedPartitions/protectedPartitions.test.ts b/packages/ats/contracts/test/contracts/integration/layer_1/protectedPartitions/protectedPartitions.test.ts index bacb0aaf70..0bcd90016e 100644 --- a/packages/ats/contracts/test/contracts/integration/layer_1/protectedPartitions/protectedPartitions.test.ts +++ b/packages/ats/contracts/test/contracts/integration/layer_1/protectedPartitions/protectedPartitions.test.ts @@ -377,7 +377,7 @@ export function protectedPartitionsTests(getCtx: () => AssetMockCtx): void { await grantKyc(); domain.name = (await asset.getERC20Metadata()).info.name; - domain.version = (await asset.getConfigInfo()).version_.toString(); + domain.version = (await asset.getConfigInfo()).configurationVersion_.toString(); domain.chainId = await network.provider.send("eth_chainId"); domain.verifyingContract = asset.target as string; }); diff --git a/packages/ats/contracts/test/contracts/integration/protectedHoldByPartition/protectedHoldByPartition.test.ts b/packages/ats/contracts/test/contracts/integration/protectedHoldByPartition/protectedHoldByPartition.test.ts index 2f41035fff..b8bb507519 100644 --- a/packages/ats/contracts/test/contracts/integration/protectedHoldByPartition/protectedHoldByPartition.test.ts +++ b/packages/ats/contracts/test/contracts/integration/protectedHoldByPartition/protectedHoldByPartition.test.ts @@ -137,7 +137,7 @@ export function protectedHoldByPartitionTests(getCtx: () => AssetMockCtx): void await asset.connect(signer_B).protectPartitions(); domain.name = (await asset.getERC20Metadata()).info.name; - domain.version = (await asset.getConfigInfo()).version_.toString(); + domain.version = (await asset.getConfigInfo()).configurationVersion_.toString(); domain.chainId = await network.provider.send("eth_chainId"); domain.verifyingContract = ctx.diamond.target as string; diff --git a/packages/ats/contracts/test/contracts/integration/resolver/BusinessLogicResolver.test.ts b/packages/ats/contracts/test/contracts/integration/resolver/BusinessLogicResolver.test.ts index 238402feb1..136914b4dd 100644 --- a/packages/ats/contracts/test/contracts/integration/resolver/BusinessLogicResolver.test.ts +++ b/packages/ats/contracts/test/contracts/integration/resolver/BusinessLogicResolver.test.ts @@ -16,7 +16,7 @@ import { KycFacet__factory, LockFacet, } from "@contract-types"; -import { EQUITY_CONFIG_ID, ATS_ROLES } from "@scripts"; +import { EQUITY_CONFIG_ID, ATS_ROLES, ADDRESS_ZERO } from "@scripts"; import { deployOrchestratorLibraries, getFacetLibraryLinks, hasOrchestratorLibraryAddresses } from "@scripts/domain"; import { HardhatEthersSigner } from "@nomicfoundation/hardhat-ethers/signers.js"; @@ -123,6 +123,21 @@ describe("BusinessLogicResolver", () => { businessLogicResolver.removeSelectorsFromBlacklist(EQUITY_CONFIG_ID, ["0x8456cb59"]), ).to.be.revertedWithCustomError(businessLogicResolver, "IsPaused"); }); + + it("GIVEN a paused contract WHEN updateReplacementAddress is called THEN transaction fails with IsPaused", async () => { + await expect( + businessLogicResolver.updateReplacementAddress( + "0x0102030405010203040501020304050102030405", + "0x0504030201050403020105040302010504030201", + ), + ).to.be.revertedWithCustomError(businessLogicResolver, "IsPaused"); + }); + + it("GIVEN a paused contract WHEN removeReplacementAddress is called THEN transaction fails with IsPaused", async () => { + await expect( + businessLogicResolver.removeReplacementAddress("0x0102030405010203040501020304050102030405"), + ).to.be.revertedWithCustomError(businessLogicResolver, "IsPaused"); + }); }); describe("AccessControl", () => { @@ -148,6 +163,23 @@ describe("BusinessLogicResolver", () => { businessLogicResolver.connect(signer_C).removeSelectorsFromBlacklist(EQUITY_CONFIG_ID, blackListedSelectors), ).to.be.revertedWithCustomError(businessLogicResolver, "AccountHasNoRole"); }); + + it("GIVEN an account without admin role WHEN updating replacement address THEN transaction fails with AccountHasNoRole", async () => { + await expect( + businessLogicResolver + .connect(signer_C) + .updateReplacementAddress( + "0x0102030405010203040501020304050102030405", + "0x0504030201050403020105040302010504030201", + ), + ).to.be.revertedWithCustomError(businessLogicResolver, "AccountHasNoRole"); + }); + + it("GIVEN an account without admin role WHEN removing replacement address THEN transaction fails with AccountHasNoRole", async () => { + await expect( + businessLogicResolver.connect(signer_C).removeReplacementAddress("0x0102030405010203040501020304050102030405"), + ).to.be.revertedWithCustomError(businessLogicResolver, "AccountHasNoRole"); + }); }); describe("Business Logic Resolver functionality", () => { @@ -357,6 +389,36 @@ describe("BusinessLogicResolver", () => { await businessLogicResolver.removeSelectorsFromBlacklist(EQUITY_CONFIG_ID, blackListedSelectors); expect(await businessLogicResolver.getSelectorsBlacklist(EQUITY_CONFIG_ID, 0, 100)).to.deep.equal([]); }); + + it("GIVEN address zero WHEN replacing it THEN transaction fails with ZeroAddressNotAllowed", async () => { + await expect( + businessLogicResolver.updateReplacementAddress(ADDRESS_ZERO, "0x0504030201050403020105040302010504030201"), + ).to.be.revertedWithCustomError(businessLogicResolver, "ZeroAddressNotAllowed"); + }); + + it("GIVEN address zero WHEN using it to replace another one THEN transaction fails with ZeroAddressNotAllowed", async () => { + await expect( + businessLogicResolver.updateReplacementAddress("0x0504030201050403020105040302010504030201", ADDRESS_ZERO), + ).to.be.revertedWithCustomError(businessLogicResolver, "ZeroAddressNotAllowed"); + }); + + it("GIVEN an address WHEN replacing it then removing itTHEN transactions success", async () => { + const replacedAddress = "0x0102030405010203040501020304050102030405"; + const newAddress = "0x0504030201050403020105040302010504030201"; + await expect(businessLogicResolver.updateReplacementAddress(replacedAddress, newAddress)) + .to.emit(businessLogicResolver, "ReplacementAddressUpdated") + .withArgs(replacedAddress, newAddress); + + const replacementAddress = await businessLogicResolver.getReplacementAddress(replacedAddress); + expect(replacementAddress).to.equal(newAddress); + + await expect(businessLogicResolver.removeReplacementAddress(replacedAddress)) + .to.emit(businessLogicResolver, "ReplacementAddressRemoved") + .withArgs(replacedAddress, newAddress); + + const replacementAddressAfterRemoval = await businessLogicResolver.getReplacementAddress(replacedAddress); + expect(replacementAddressAfterRemoval).to.equal(ADDRESS_ZERO); + }); }); it("GIVEN a facet registered with a mismatched key WHEN registerBusinessLogics THEN fails with BusinessLogicKeyMismatch", async () => { diff --git a/packages/ats/contracts/test/contracts/integration/resolver/diamondCutManager.test.ts b/packages/ats/contracts/test/contracts/integration/resolver/diamondCutManager.test.ts index c11ca8f56f..5616815595 100644 --- a/packages/ats/contracts/test/contracts/integration/resolver/diamondCutManager.test.ts +++ b/packages/ats/contracts/test/contracts/integration/resolver/diamondCutManager.test.ts @@ -39,6 +39,9 @@ const TEST_CONFIG_IDS = { BLACKLIST_TEST: "0x0000000000000000000000000000000000000000000000000000000000000006", }; +const RESOLVER_PROXY_VERSION_V2 = "0x0000000000000002"; // bytes8 +const PAUSE_SELECTOR = "0x8456cb59"; + describe("DiamondCutManager", () => { function createFacetConfigurations(ids: string[], versions: number[]): IDiamondCutManager.FacetConfigurationStruct[] { return ids.map((id, index) => ({ @@ -69,6 +72,33 @@ describe("DiamondCutManager", () => { return await deployAtsInfrastructureFixture(); } + function buildBytes( + resolverProxyVersion: string, + configId: string, + configurationVersion: number, + replacementEnabled: boolean, + ): string { + const coder = ethers.AbiCoder.defaultAbiCoder(); + + // content = abi.encode(ResolverProxyConfigurationV2{ configurationId, configurationVersion, replacementEnabled }) + const content = coder.encode( + ["tuple(bytes32 configurationId, uint256 configurationVersion, bool replacementEnabled)"], + [ + { + configurationId: configId, + configurationVersion: configurationVersion, + replacementEnabled: replacementEnabled, + }, + ], + ); + + // resolverProxyConfiguration = abi.encode(ResolverProxyConfigurationGeneric{ resolverProxyVersion, content }) + return coder.encode( + ["tuple(bytes8 resolverProxyVersion, bytes content)"], + [{ resolverProxyVersion: resolverProxyVersion, content }], + ); + } + beforeEach(async () => { const infrastructure = await loadFixture(atsInfrastructureFixture); @@ -111,7 +141,6 @@ describe("DiamondCutManager", () => { if (isPaused) { await pause.connect(signer_B).unpause(); } - const pauseSelector = "0x8456cb59"; const configIdsToCleanup = [ EQUITY_CONFIG_ID, TEST_CONFIG_IDS.PAUSE_TEST, @@ -121,7 +150,7 @@ describe("DiamondCutManager", () => { for (const configId of configIdsToCleanup) { try { - await businessLogicResolver.removeSelectorsFromBlacklist(configId, [pauseSelector]); + await businessLogicResolver.removeSelectorsFromBlacklist(configId, [PAUSE_SELECTOR]); } catch (_error) { // Ignore errors if selector wasn't blacklisted - contract may be in different state } @@ -272,7 +301,14 @@ describe("DiamondCutManager", () => { selectorId, ); + const resolverProxyConfiguration = buildBytes(RESOLVER_PROXY_VERSION_V2, configId, configVersion, false); + const facetAddressForSelector = await diamondCutManager.resolveResolverProxyCall( + resolverProxyConfiguration, + selectorId, + ); + + const facetAddressForSelectorLegacy = await diamondCutManager["resolveResolverProxyCall(bytes32,uint256,bytes4)"]( configId, configVersion, selectorId, @@ -281,6 +317,7 @@ describe("DiamondCutManager", () => { expect(facetAddressForSelector).to.not.equal("0x0000000000000000000000000000000000000000"); expect(id).to.equal(facet.id); expect(facetAddressForSelector).to.equal(facet.addr); + expect(facetAddressForSelector).to.equal(facetAddressForSelectorLegacy); } } @@ -382,7 +419,9 @@ describe("DiamondCutManager", () => { ), ).to.be.revertedWithCustomError(diamondCutManager, "ResolverProxyConfigurationNoRegistered"); - const noFacetAddress = await diamondCutManager.resolveResolverProxyCall(EQUITY_CONFIG_ID, 1, "0x00000001"); + const resolverProxyConfiguration = buildBytes(RESOLVER_PROXY_VERSION_V2, EQUITY_CONFIG_ID, 1, false); + + const noFacetAddress = await diamondCutManager.resolveResolverProxyCall(resolverProxyConfiguration, "0x00000001"); expect(noFacetAddress).to.equal("0x0000000000000000000000000000000000000000"); const interfaceDoesnotExist = await diamondCutManager.resolveSupportsInterface(EQUITY_CONFIG_ID, 1, "0x00000001"); @@ -490,7 +529,7 @@ describe("DiamondCutManager", () => { // Cancel the incomplete batch configuration and verify event is emitted await expect(diamondCutManager.connect(signer_A).cancelBatchConfiguration(testConfigId)) - .to.emit(diamondCutManager, "DiamondBatchConfigurationCanceled") + .to.emit(diamondCutManager, "DiamondBatchConfigurationCancelled") .withArgs(testConfigId, 1); // Verify all information is removed @@ -887,12 +926,48 @@ describe("DiamondCutManager", () => { }); it("GIVEN an existing configuration WHEN resolving a call with version 0 THEN reverts with VersionZero", async () => { - const pauseSelector = "0x8456cb59"; - await expect(diamondCutManager.resolveResolverProxyCall(EQUITY_CONFIG_ID, 0, pauseSelector)) + const resolverProxyConfiguration = buildBytes(RESOLVER_PROXY_VERSION_V2, EQUITY_CONFIG_ID, 0, false); + + await expect(diamondCutManager.resolveResolverProxyCall(resolverProxyConfiguration, PAUSE_SELECTOR)) .to.be.revertedWithCustomError(diamondCutManager, "VersionZero") .withArgs(EQUITY_CONFIG_ID); }); + it("GIVEN an existing configuration WHEN resolving a call with version 0 for legacy method THEN reverts with VersionZero", async () => { + await expect( + diamondCutManager["resolveResolverProxyCall(bytes32,uint256,bytes4)"](EQUITY_CONFIG_ID, 0, PAUSE_SELECTOR), + ) + .to.be.revertedWithCustomError(diamondCutManager, "VersionZero") + .withArgs(EQUITY_CONFIG_ID); + }); + + it("GIVEN a wrong proxy configuration with a bytes that is not a multiple of 32 WHEN resolving a call THEN reverts with InvalidResolverProxyConfiguration", async () => { + const resolverProxyConfiguration = "0x01"; + + await expect(diamondCutManager.resolveResolverProxyCall(resolverProxyConfiguration, PAUSE_SELECTOR)) + .to.be.revertedWithCustomError(diamondCutManager, "InvalidResolverProxyConfiguration") + .withArgs(resolverProxyConfiguration); + }); + + it("GIVEN a wrong proxy configuration with too few bytes WHEN resolving a call THEN reverts with InvalidResolverProxyConfiguration", async () => { + let resolverProxyConfiguration = buildBytes(RESOLVER_PROXY_VERSION_V2, EQUITY_CONFIG_ID, 0, false); + resolverProxyConfiguration = resolverProxyConfiguration.substring(0, resolverProxyConfiguration.length - 2); + + await expect(diamondCutManager.resolveResolverProxyCall(resolverProxyConfiguration, PAUSE_SELECTOR)) + .to.be.revertedWithCustomError(diamondCutManager, "InvalidResolverProxyConfiguration") + .withArgs(resolverProxyConfiguration); + }); + + it("GIVEN an unrecognized proxy version WHEN resolving a call THEN reverts with UnrecognizedResolverProxyVersion", async () => { + const WRONG_RESOLVER_PROXY_VERSION = "0xffffffffffffffff"; + + const resolverProxyConfiguration = buildBytes(WRONG_RESOLVER_PROXY_VERSION, EQUITY_CONFIG_ID, 0, false); + + await expect(diamondCutManager.resolveResolverProxyCall(resolverProxyConfiguration, PAUSE_SELECTOR)) + .to.be.revertedWithCustomError(diamondCutManager, "UnrecognizedResolverProxyVersion") + .withArgs(WRONG_RESOLVER_PROXY_VERSION); + }); + it("GIVEN an existing configuration WHEN resolveSupportsInterface called with version 0 THEN reverts with VersionZero", async () => { await expect(diamondCutManager.resolveSupportsInterface(EQUITY_CONFIG_ID, 0, "0x01ffc9a7")) .to.be.revertedWithCustomError(diamondCutManager, "VersionZero") diff --git a/packages/ats/contracts/test/contracts/integration/resolverProxy/resolverProxy.test.ts b/packages/ats/contracts/test/contracts/integration/resolverProxy/resolverProxy.test.ts index 48ae966fe4..14d9e7eaa3 100644 --- a/packages/ats/contracts/test/contracts/integration/resolverProxy/resolverProxy.test.ts +++ b/packages/ats/contracts/test/contracts/integration/resolverProxy/resolverProxy.test.ts @@ -114,7 +114,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, []); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target); @@ -122,7 +122,8 @@ describe("ResolverProxy Tests", () => { expect(result.resolver_).to.equal(resolver.target); expect(result.configurationId_).to.equal(CONFIG_ID); - expect(result.version_).to.equal(1); + expect(result.configurationVersion_).to.equal(1); + expect(result.replacementEnabled_).to.equal(false); const diamondLoupe = await ethers.getContractAt("DiamondFacet", resolverProxy.target); @@ -141,7 +142,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, []); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); const accessControl = await ethers.getContractAt("AccessControl", resolverProxy.target); const diamondLoupe = await ethers.getContractAt("DiamondFacet", resolverProxy.target); @@ -184,7 +185,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy_v1 = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, []); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); const diamondFacet_v1 = await ethers.getContractAt("DiamondFacet", resolverProxy_v1.target); await checkFacets(businessLogicsRegistryDatas_1, diamondFacet_v1); @@ -195,7 +196,11 @@ describe("ResolverProxy Tests", () => { const resolverProxy_v2 = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, latestVersion, []); + ).deploy( + resolver.target, + { configurationId: CONFIG_ID, configurationVersion: latestVersion, replacementEnabled: false }, + [], + ); const diamondFacet_v2 = await ethers.getContractAt("DiamondFacet", resolverProxy_v2.target); await checkFacets(businessLogicsRegistryDatas_1, diamondFacet_v1); @@ -218,7 +223,13 @@ describe("ResolverProxy Tests", () => { const resolverProxyFactory = await ethers.getContractFactory("ResolverProxy"); - await expect(resolverProxyFactory.deploy(resolver.target, CONFIG_ID, 0, [])) + await expect( + resolverProxyFactory.deploy( + resolver.target, + { configurationId: CONFIG_ID, configurationVersion: 0, replacementEnabled: false }, + [], + ), + ) .to.be.revertedWithCustomError(resolver, "VersionZero") .withArgs(CONFIG_ID); }); @@ -239,7 +250,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, []); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target); @@ -269,7 +280,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, rbac); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, rbac); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); @@ -304,7 +315,11 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, oldVersion, rbac); + ).deploy( + resolver.target, + { configurationId: CONFIG_ID, configurationVersion: oldVersion, replacementEnabled: false }, + rbac, + ); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); @@ -312,7 +327,8 @@ describe("ResolverProxy Tests", () => { expect(result.resolver_).to.equal(resolver.target); expect(result.configurationId_).to.equal(CONFIG_ID); - expect(result.version_).to.equal(oldVersion); + expect(result.configurationVersion_).to.equal(oldVersion); + expect(result.replacementEnabled_).to.equal(false); const newVersion = 1; @@ -322,7 +338,87 @@ describe("ResolverProxy Tests", () => { expect(result.resolver_).to.equal(resolver.target); expect(result.configurationId_).to.equal(CONFIG_ID); - expect(result.version_).to.equal(newVersion); + expect(result.configurationVersion_).to.equal(newVersion); + expect(result.replacementEnabled_).to.equal(false); + }); + + it("GIVEN resolverProxy and non-admin user WHEN updating replacement enabled flag THEN fails with AccountHasNoRole", async () => { + const businessLogicsRegistryDatas = [ + { + businessLogicKey: await diamondFacet.getStaticResolverKey(), + businessLogicAddress: diamondFacet.target, + }, + { + businessLogicKey: await accessControlImpl.getStaticResolverKey(), + businessLogicAddress: accessControlImpl.target, + }, + ]; + + await setUpResolver(businessLogicsRegistryDatas); + + const resolverProxy = await ( + await ethers.getContractFactory("ResolverProxy") + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); + + const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target); + + await expect(diamondCut.updateReplacementEnabled(true)).to.be.revertedWithCustomError( + diamondCut, + "AccountHasNoRole", + ); + }); + + it("GIVEN resolverProxy and admin user WHEN updating replacement enabled flag THEN succeeds", async () => { + const businessLogicsRegistryDatas = [ + { + businessLogicKey: await diamondFacet.getStaticResolverKey(), + businessLogicAddress: diamondFacet.target, + }, + { + businessLogicKey: await accessControlImpl.getStaticResolverKey(), + businessLogicAddress: accessControlImpl.target, + }, + ]; + + await setUpResolver(businessLogicsRegistryDatas); + + const rbac = [ + { + role: ATS_ROLES.DEFAULT_ADMIN_ROLE, + members: [signer_A.address], + }, + ]; + + const version = 1; + const oldReplacementEnabledFlag = false; + + const resolverProxy = await ( + await ethers.getContractFactory("ResolverProxy") + ).deploy( + resolver.target, + { configurationId: CONFIG_ID, configurationVersion: version, replacementEnabled: oldReplacementEnabledFlag }, + rbac, + ); + + const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); + + let result = await diamondCut.getConfigInfo(); + + expect(result.resolver_).to.equal(resolver.target); + expect(result.configurationId_).to.equal(CONFIG_ID); + expect(result.configurationVersion_).to.equal(version); + expect(result.replacementEnabled_).to.equal(oldReplacementEnabledFlag); + + const newReplacementEnabledFlag = !oldReplacementEnabledFlag; + + await diamondCut.updateReplacementEnabled(newReplacementEnabledFlag); + + result = await diamondCut.getConfigInfo(); + + expect(result.resolver_).to.equal(resolver.target); + expect(result.configurationId_).to.equal(CONFIG_ID); + expect(result.configurationVersion_).to.equal(version); + expect(result.replacementEnabled_).to.equal(newReplacementEnabledFlag); }); it("GIVEN resolverProxy and non-admin user WHEN updating configID THEN fails with AccountHasNoRole", async () => { @@ -341,7 +437,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, []); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target); @@ -371,7 +467,7 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, rbac); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, rbac); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); @@ -407,7 +503,11 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, oldVersion, rbac); + ).deploy( + resolver.target, + { configurationId: CONFIG_ID, configurationVersion: oldVersion, replacementEnabled: false }, + rbac, + ); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); @@ -415,7 +515,8 @@ describe("ResolverProxy Tests", () => { expect(result.resolver_).to.equal(resolver.target); expect(result.configurationId_).to.equal(CONFIG_ID); - expect(result.version_).to.equal(oldVersion); + expect(result.configurationVersion_).to.equal(oldVersion); + expect(result.replacementEnabled_).to.equal(false); const newVersion = 1; @@ -425,7 +526,8 @@ describe("ResolverProxy Tests", () => { expect(result.resolver_).to.equal(resolver.target); expect(result.configurationId_).to.equal(CONFIG_ID_2); - expect(result.version_).to.equal(newVersion); + expect(result.configurationVersion_).to.equal(newVersion); + expect(result.replacementEnabled_).to.equal(false); }); it("GIVEN resolverProxy and non-admin user WHEN updating resolver THEN fails with AccountHasNoRole", async () => { @@ -446,11 +548,11 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, []); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, []); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target); - await expect(diamondCut.updateResolver(resolver_2.target, CONFIG_ID_2, 1)).to.be.revertedWithCustomError( + await expect(diamondCut.updateResolver(resolver_2.target, CONFIG_ID_2, 1, true)).to.be.revertedWithCustomError( diamondCut, "AccountHasNoRole", ); @@ -481,11 +583,11 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, 1, rbac); + ).deploy(resolver.target, { configurationId: CONFIG_ID, configurationVersion: 1, replacementEnabled: false }, rbac); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); - await expect(diamondCut.updateResolver(resolver_2.target, CONFIG_ID_2, 1)).to.be.revertedWithCustomError( + await expect(diamondCut.updateResolver(resolver_2.target, CONFIG_ID_2, 1, true)).to.be.revertedWithCustomError( resolver, "ResolverProxyConfigurationNoRegistered", ); @@ -519,7 +621,11 @@ describe("ResolverProxy Tests", () => { const resolverProxy = await ( await ethers.getContractFactory("ResolverProxy") - ).deploy(resolver.target, CONFIG_ID, oldVersion, rbac); + ).deploy( + resolver.target, + { configurationId: CONFIG_ID, configurationVersion: oldVersion, replacementEnabled: false }, + rbac, + ); const diamondCut = await ethers.getContractAt("DiamondFacet", resolverProxy.target, signer_A); @@ -527,16 +633,18 @@ describe("ResolverProxy Tests", () => { expect(result.resolver_).to.equal(resolver.target); expect(result.configurationId_).to.equal(CONFIG_ID); - expect(result.version_).to.equal(oldVersion); + expect(result.configurationVersion_).to.equal(oldVersion); + expect(result.replacementEnabled_).to.equal(false); const newVersion = 1; - await diamondCut.updateResolver(resolver_2.target, CONFIG_ID_2, newVersion); + await diamondCut.updateResolver(resolver_2.target, CONFIG_ID_2, newVersion, true); result = await diamondCut.getConfigInfo(); expect(result.resolver_).to.equal(resolver_2.target); expect(result.configurationId_).to.equal(CONFIG_ID_2); - expect(result.version_).to.equal(newVersion); + expect(result.configurationVersion_).to.equal(newVersion); + expect(result.replacementEnabled_).to.equal(true); }); }); diff --git a/packages/ats/contracts/test/fixtures/resolverProxy.fixture.ts b/packages/ats/contracts/test/fixtures/resolverProxy.fixture.ts index a7dab13059..03fc825f2d 100644 --- a/packages/ats/contracts/test/fixtures/resolverProxy.fixture.ts +++ b/packages/ats/contracts/test/fixtures/resolverProxy.fixture.ts @@ -140,8 +140,7 @@ export async function deployResolverProxyFixture(): Promise { expect(result.previousConfig).to.deep.include({ resolver: blrAddress, configurationId: configId, - version: BLR_VERSIONS.FIRST, + configurationVersion: BLR_VERSIONS.FIRST, }); expect(result.newConfig).to.deep.include({ resolver: blrAddress, configurationId: configId, - version: BLR_VERSIONS.SECOND, + configurationVersion: BLR_VERSIONS.SECOND, }); }); @@ -87,7 +87,7 @@ describe("updateResolverProxy* - Integration Tests", () => { // Verify initial version const configBefore = await getResolverProxyConfigInfo(deployer, proxyAddress); - expect(configBefore.version).to.equal(BLR_VERSIONS.FIRST); + expect(configBefore.configurationVersion).to.equal(BLR_VERSIONS.FIRST); // Update version await updateResolverProxyVersion(deployer, proxyAddress, initialVersion + 1, { @@ -96,7 +96,7 @@ describe("updateResolverProxy* - Integration Tests", () => { // Verify new version on-chain const configAfter = await getResolverProxyConfigInfo(deployer, proxyAddress); - expect(configAfter.version).to.equal(BLR_VERSIONS.SECOND); + expect(configAfter.configurationVersion).to.equal(BLR_VERSIONS.SECOND); }); }); @@ -113,7 +113,7 @@ describe("updateResolverProxy* - Integration Tests", () => { expect(result.success).to.be.true; expect(result.updateType).to.equal("config"); expect(result.newConfig?.configurationId).to.equal(altConfigId); - expect(result.newConfig?.version).to.equal(BLR_VERSIONS.SECOND); + expect(result.newConfig?.configurationVersion).to.equal(BLR_VERSIONS.SECOND); }); it("should verify configId changed on-chain", async () => { @@ -349,7 +349,7 @@ describe("updateResolverProxy* - Integration Tests", () => { // Verify persistence by reading again const configInfo = await getResolverProxyConfigInfo(deployer, proxyAddress); - expect(configInfo.version).to.equal(BLR_VERSIONS.SECOND); + expect(configInfo.configurationVersion).to.equal(BLR_VERSIONS.SECOND); }); it("should allow subsequent version updates within registered versions", async () => { @@ -363,7 +363,7 @@ describe("updateResolverProxy* - Integration Tests", () => { // Verify final state is at max registered version const configInfo = await getResolverProxyConfigInfo(deployer, proxyAddress); - expect(configInfo.version).to.equal(maxVersion); + expect(configInfo.configurationVersion).to.equal(maxVersion); }); it("should allow subsequent config updates", async () => { @@ -380,7 +380,7 @@ describe("updateResolverProxy* - Integration Tests", () => { // Verify final state const configInfo = await getResolverProxyConfigInfo(deployer, proxyAddress); expect(configInfo.configurationId).to.equal(altConfigId); - expect(configInfo.version).to.equal(initialVersion + 1); + expect(configInfo.configurationVersion).to.equal(initialVersion + 1); }); }); diff --git a/packages/ats/contracts/test/scripts/integration/upgradeConfigurations.test.ts b/packages/ats/contracts/test/scripts/integration/upgradeConfigurations.test.ts index 685ce3957a..17cb4d8d70 100644 --- a/packages/ats/contracts/test/scripts/integration/upgradeConfigurations.test.ts +++ b/packages/ats/contracts/test/scripts/integration/upgradeConfigurations.test.ts @@ -133,7 +133,7 @@ describe("upgradeConfigurations - Integration Tests", () => { // Verify initial version const configBefore = await getResolverProxyConfigInfo(deployer, equityTokenAddress); - expect(configBefore.version).to.equal(1); + expect(configBefore.configurationVersion).to.equal(1); const result = await upgradeConfigurations(deployer, "hardhat", { blrAddress, @@ -155,7 +155,7 @@ describe("upgradeConfigurations - Integration Tests", () => { // Verify version was updated on-chain const configAfter = await getResolverProxyConfigInfo(deployer, equityTokenAddress); - expect(configAfter.version).to.equal(2); + expect(configAfter.configurationVersion).to.equal(2); }); it("should update multiple proxies successfully", async () => { @@ -180,8 +180,8 @@ describe("upgradeConfigurations - Integration Tests", () => { // Verify both proxies were updated const equityConfig = await getResolverProxyConfigInfo(deployer, equityTokenAddress); const bondConfig = await getResolverProxyConfigInfo(deployer, bondTokenAddress); - expect(equityConfig.version).to.equal(2); - expect(bondConfig.version).to.equal(2); + expect(equityConfig.configurationVersion).to.equal(2); + expect(bondConfig.configurationVersion).to.equal(2); }); it("should continue on partial proxy update failures", async () => { diff --git a/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondToken.test.ts b/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondToken.test.ts index e22d7d1c9d..a6c9b12932 100644 --- a/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondToken.test.ts +++ b/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondToken.test.ts @@ -106,12 +106,12 @@ describe("Bond Token Deployment", () => { await deployBondFromFactory(params, regulationData); const callArgs = mockFactory.deployBond.getCall(0).args[0]; - const config = callArgs.security.resolverProxyConfiguration; + const config = callArgs.security.resolverProxyConfigurationV2; - expect(config.key).to.equal(BOND_CONFIG_ID); + expect(config.configurationId).to.equal(BOND_CONFIG_ID); }); - it("should set version to 1", async () => { + it("should set configurationVersion to 1", async () => { const diamondAddress = TEST_ADDRESSES.VALID_3; const mockFactory = createMockFactory(TEST_FACTORY_EVENTS.BOND_DEPLOYED, diamondAddress); const params = createDeployBondParams(mockFactory); @@ -120,9 +120,23 @@ describe("Bond Token Deployment", () => { await deployBondFromFactory(params, regulationData); const callArgs = mockFactory.deployBond.getCall(0).args[0]; - const config = callArgs.security.resolverProxyConfiguration; + const config = callArgs.security.resolverProxyConfigurationV2; - expect(config.version).to.equal(1); + expect(config.configurationVersion).to.equal(1); + }); + + it("should set replacementEnabled to true", async () => { + const diamondAddress = TEST_ADDRESSES.VALID_3; + const mockFactory = createMockFactory(TEST_FACTORY_EVENTS.BOND_DEPLOYED, diamondAddress); + const params = createDeployBondParams(mockFactory); + const regulationData = createMockRegulationData(); + + await deployBondFromFactory(params, regulationData); + + const callArgs = mockFactory.deployBond.getCall(0).args[0]; + const config = callArgs.security.resolverProxyConfigurationV2; + + expect(config.replacementEnabled).to.equal(true); }); }); diff --git a/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondVariants.test.ts b/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondVariants.test.ts index 1e5c3474d9..da829c5303 100644 --- a/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondVariants.test.ts +++ b/packages/ats/contracts/test/scripts/unit/domain/factory/deployBondVariants.test.ts @@ -85,9 +85,9 @@ describe("Bond Variant Deployments", () => { await deployBondFixedRateFromFactory(params, regulationData, fixedRateParams); const callArgs = mockFactory.deployBondFixedRate.getCall(0).args[0]; - const config = callArgs.bondData.security.resolverProxyConfiguration; + const config = callArgs.bondData.security.resolverProxyConfigurationV2; - expect(config.key).to.equal(BOND_FIXED_RATE_CONFIG_ID); + expect(config.configurationId).to.equal(BOND_FIXED_RATE_CONFIG_ID); }); }); @@ -249,9 +249,9 @@ describe("Bond Variant Deployments", () => { await deployBondKpiLinkedRateFromFactory(params, regulationData, interestRateParams, impactDataParams); const callArgs = mockFactory.deployBondKpiLinkedRate.getCall(0).args[0]; - const config = callArgs.bondData.security.resolverProxyConfiguration; + const config = callArgs.bondData.security.resolverProxyConfigurationV2; - expect(config.key).to.equal(BOND_KPI_LINKED_RATE_CONFIG_ID); + expect(config.configurationId).to.equal(BOND_KPI_LINKED_RATE_CONFIG_ID); }); }); diff --git a/packages/ats/contracts/test/scripts/unit/domain/factory/deployEquityToken.test.ts b/packages/ats/contracts/test/scripts/unit/domain/factory/deployEquityToken.test.ts index 84340b369b..229c4da3ae 100644 --- a/packages/ats/contracts/test/scripts/unit/domain/factory/deployEquityToken.test.ts +++ b/packages/ats/contracts/test/scripts/unit/domain/factory/deployEquityToken.test.ts @@ -107,12 +107,12 @@ describe("Equity Token Deployment", () => { await deployEquityFromFactory(params, regulationData); const callArgs = mockFactory.deployEquity.getCall(0).args[0]; - const config = callArgs.security.resolverProxyConfiguration; + const config = callArgs.security.resolverProxyConfigurationV2; - expect(config.key).to.equal(EQUITY_CONFIG_ID); + expect(config.configurationId).to.equal(EQUITY_CONFIG_ID); }); - it("should set version to 1", async () => { + it("should set configurationVersion to 1", async () => { const diamondAddress = TEST_ADDRESSES.VALID_3; const mockFactory = createMockFactory(TEST_FACTORY_EVENTS.EQUITY_DEPLOYED, diamondAddress); const params = createDeployEquityParams(mockFactory); @@ -121,9 +121,23 @@ describe("Equity Token Deployment", () => { await deployEquityFromFactory(params, regulationData); const callArgs = mockFactory.deployEquity.getCall(0).args[0]; - const config = callArgs.security.resolverProxyConfiguration; + const config = callArgs.security.resolverProxyConfigurationV2; - expect(config.version).to.equal(1); + expect(config.configurationVersion).to.equal(1); + }); + + it("should set replacementEnabled to true", async () => { + const diamondAddress = TEST_ADDRESSES.VALID_3; + const mockFactory = createMockFactory(TEST_FACTORY_EVENTS.EQUITY_DEPLOYED, diamondAddress); + const params = createDeployEquityParams(mockFactory); + const regulationData = createMockRegulationData(); + + await deployEquityFromFactory(params, regulationData); + + const callArgs = mockFactory.deployEquity.getCall(0).args[0]; + const config = callArgs.security.resolverProxyConfigurationV2; + + expect(config.replacementEnabled).to.equal(true); }); }); diff --git a/packages/ats/contracts/test/scripts/unit/domain/factory/helpers/mockFactories.ts b/packages/ats/contracts/test/scripts/unit/domain/factory/helpers/mockFactories.ts index 25c01cdf20..07de778ab5 100644 --- a/packages/ats/contracts/test/scripts/unit/domain/factory/helpers/mockFactories.ts +++ b/packages/ats/contracts/test/scripts/unit/domain/factory/helpers/mockFactories.ts @@ -60,9 +60,10 @@ export function createMockSecurityData(overrides?: Partial): externalKycLists: [], compliance: TEST_ADDRESSES.ZERO, identityRegistry: TEST_ADDRESSES.ZERO, - resolverProxyConfiguration: { - key: TEST_CONFIG_IDS.EQUITY, - version: 1, + resolverProxyConfigurationV2: { + configurationId: TEST_CONFIG_IDS.EQUITY, + configurationVersion: 1, + replacementEnabled: true, }, rbacs: [], ...overrides,