Module pool_derivation

Module pool_derivation 

Source
Expand description

SPL interface PDA derivation utilities for Light Protocol.

This module provides functions to derive SPL interface PDAs (token pools) for both regular and restricted mints. Restricted mints (those with Pausable, PermanentDelegate, TransferFeeConfig, TransferHook, or DefaultAccountState extensions) use a different derivation path to prevent accidental compression via legacy anchor instructions.

Constants§

NUM_MAX_POOL_ACCOUNTS
Maximum number of pool accounts per mint.

Functions§

find_spl_interface_pda
Find the SPL interface PDA for a given mint (index 0).
find_spl_interface_pda_with_index
Find the SPL interface PDA for a given mint and index.
get_spl_interface_pda
Get the SPL interface PDA address for a given mint (index 0).
has_restricted_extensions
Check if a mint has any restricted extensions.
is_valid_spl_interface_pda
Validate that an SPL interface PDA is correctly derived.