A Solana program implementation of SRFC37 - a permissioned token standard that enables allow/block listing without compromising user experience or developer composability.
Token ACL provides a novel mechanism for permissioned tokens using Token22's Default Account State extension and a delegated freeze authority. This approach eliminates the UX friction of manual token account thawing while maintaining protocol composability.
- Token ACL Program (
/program): Core smart contract that manages freeze authority delegation and permissionless thaw/freeze operations - Interface Package (
/interface): Defines instruction discriminators and provides on/offchain account resolution for gate program implementers - Client Libraries (
/clients): SDKs for TypeScript, Rust, and CLI interaction - Examples (
/examples): Reference implementations of gate programs for testing
- Managed Freeze Authority: Token ACL manages the mint freeze authority
- Permissionless Thaw/Freeze: Users can thaw/freeze token accounts without issuer intervention
- Gate Program Interface: Standardized interface for custom allow/block list logic
- Composability: Works with existing protocols without requiring specialized UIs
- Security: De-escalated permissions prevent malicious instruction injection
- Rust 1.70+
- Solana CLI 2.2.0+
- Node.js 18+ (for TypeScript client)
# Clone the repository
git clone https://github.com/solana-foundation/token-acl.git
cd token-acl
# Build all components
cargo build --release
# Install CLI
cargo install --path clients/cli# Create a mint configuration
token-acl create-config <MINT_ADDRESS> --authority <AUTHORITY_KEYPAIR>
# Set a gate program
token-acl set-gating-program <MINT_ADDRESS> <GATE_PROGRAM_ID>
# Enable permissionless thaw
token-acl enable-permissionless-thaw <MINT_ADDRESS>always-allow: Always permits thaw/freeze operationsalways-block: Always blocks thaw/freeze operationsalways-allow-with-deps: Example with additional account dependencies
This implementation follows SRFC37 which defines:
- Token ACL program interface and account structures
- Gate program interface with standardized discriminators
- Extra account metas resolution for dynamic account dependencies
- Security model with de-escalated permissions
# Run tests
cargo test
# Build program for deployment
cargo build-sbf --manifest-path program/Cargo.toml
# Run integration tests
cargo test --package token-acl --test integrationMIT License - see LICENSE file for details