Signature
IPolicyRegistry.sol
Description
Creates a composite policy that combines two to four existing simple policies (ALLOWLIST or BLOCKLIST) under a single logic gate:
The registry stores references to the children, not a snapshot of their members. Every call to
isAuthorized reads each child’s current member set, so updates to a child policy are immediately visible through the composite.
Creation is permissionless. The admin you supply is the only address that can later call updateComposite, stageUpdateAdmin, or renounceAdmin on this policy.
On success, emits PolicyCreated(newPolicyId, creator, policyType), PolicyAdminUpdated(newPolicyId, address(0), admin), and CompositePolicyUpdated(newPolicyId, creator, childPolicyIds).
Parameters
Returns
Reverts
Access Control
Permissionless, any caller may create a composite policy.Example
Create a KYC-and-sanctions composite
Updating a child policy’s membership (via
updateAllowlist or updateBlocklist) takes effect on the next isAuthorized call through any composite that references it. No second updateComposite is needed on the token.