For the complete documentation index, see llms.txt. This page is also available as Markdown.

Solana Token Delegate Authority

1. Core Mechanism: Delegation and Authority Amount

In Solana, each token account possesses a delegate field that allows for the delegation of authority.

  • Delegate Operation: By signing a transaction, you can set the delegate field of your token account to another address (typically a contract address) and specify a delegated_amount. This amount defines the limit of tokens that the delegate can transfer on your behalf.

  • Permission Transfer: Once the delegation is successfully set, the designated address (Delegate) gains the authority to transfer the specified quantity of tokens from your token account without requiring your signature for each individual transaction.

2. Risks and Precautions of Token Delegation

How to Safeguard Against Phishing Attacks and Manage Token Authorization

  • Delegate Risk: While the delegated amount is limited, if the delegate address is a malicious contract, it can execute transfers within the authorized limit at any time.

  • Revoke Delegate: Solana provides the option to revoke delegation at any moment. By invoking the Revoke instruction, you can reset the delegate field of your token account to null, effectively cutting off the delegate's transfer permissions.

  • Stay Vigilant: If you encounter a request for delegation in a non-transactional context or from an unknown DApp, this may indicate an attempt to gain unauthorized access to your account's delegation permissions, potentially leading to asset theft.

3. Key Differences from EVM Approve

Overview of Solana Delegation vs. Ethereum Approval Mechanism

Feature
Solana Delegate
EVM Approve

Target

Specific Token Account

Wallet Address (Owner)

Implementation

Modifies the delegate field of the Token Account

Alters the allowance mapping in the contract

Flexibility

Specific to the balance of that account

Specific to the allowance for that address in the contract

Revocation Method

Send Revoke instruction

Send Approve instruction with a zero amount

Was this helpful?