Address
Overview
The registry manages policies that TIP-20 tokens can reference:- Whitelists: Only listed addresses are authorized
- Blacklists: All addresses except listed ones are authorized
- Compound Policies: Separate sender/recipient policies (T2+)
- Immutability: Policies can be created but not deleted
Interface
Events
Errors
Built-in Policies
Two special policies are always available:Simple Policies
Creating a Whitelist
Creating a Blacklist
Checking Authorization
Compound Policies (T2+)
Compound policies allow different rules for senders, recipients, and mint recipients:Creating a Compound Policy
Authorization Checks
Policy Management
Updating Policy Admin
Adding/Removing from Whitelist
Adding/Removing from Blacklist
TIP-20 Integration
TIP-20 tokens reference policy IDs for transfer restrictions:Gas Costs
| Operation | Cold | Warm |
|---|---|---|
createPolicy | ~45,000 gas | ~25,000 gas |
createPolicyWithAccounts | +5,000 gas per account | +2,500 gas per account |
createCompoundPolicy | ~30,000 gas | ~15,000 gas |
modifyPolicyWhitelist | ~25,000 gas | ~10,000 gas |
modifyPolicyBlacklist | ~25,000 gas | ~10,000 gas |
isAuthorized | ~3,500 gas | ~400 gas |
isAuthorizedSender | ~3,500 gas | ~400 gas |
Storage Layout
Use Cases
KYC/AML Compliance
Sanctions Screening
Vendor Credits (T2+)
Best Practices
Policy Immutability
Admin Management
Authorization Caching
Security Considerations
- Admin Compromise: Policy admin can modify lists; use multi-sig
- Policy Immutability: Policies can’t be deleted; plan versioning
- Gas Costs: Large policy updates can be expensive; batch operations
- Compound Policies: Are immutable (no admin); choose sub-policies carefully