Skip to content

TRC20 signature validation: "not contained of permission" error with address mismatch (TRX works, USDT fails) #6412

@slaenov

Description

@slaenov

Software Versions

Note: I apologize for posting a Go implementation question in the Java TRON repository. While Go implementations exist, I'm following the official TRON documentation and API specifications, yet encountering this protocol-level signature validation issue. I'm hoping the core protocol experts here can help understand the TRON-specific signature validation differences between TRX and TRC20 transactions.

Client: Custom Go implementation using TRON API
TRON Network: Testnet
API Endpoint: TronGrid
Crypto Library: go-ethereum/crypto (latest)

Expected behaviour

TRC20 (USDT) token transfers should be signed and accepted by the TRON network using standard ECDSA signature, similar to how native TRX transfers work with the same signing implementation.

Actual behaviour

TRC20 transfers fail with signature validation error:
API error: Validate signature error: cc1de6c85da363c051ca6206a957b49a741fc1325ea6f03ec3c781886ebacbd80eff1e73d8072a9bc3e6058bf8c6043c72b0b369479cc7e25472115c388c93dc1c is signed by TJSabY59bePRMUpERghYKvfNrD8ZbYuq4Y but it is not contained of permission.

Key Issue: The address in the error (TJSabY59bePRMUpERghYKvfNrD8ZbYuq4Y) doesn't match either sender or recipient address.

Frequency

100% - Every TRC20 (USDT) transfer attempt fails with this error, while TRX transfers work perfectly.

Steps to reproduce the behaviour

  1. Create TRC20 (USDT) transfer transaction using TronGrid API triggersmartcontract
  2. Extract raw_data from transaction response, serialize to protobuf bytes
  3. Calculate SHA256 hash of the raw_data bytes
  4. Sign hash using go-ethereum/crypto ECDSA implementation
  5. Add signature to transaction and broadcast via TronGrid
  6. Observe signature validation error

Files to reproduce the error: https://gist.github.com/slaenov/1676ac20fc9f5cdd4989b562850162d3

TRON-Specific Questions

  • Is there a difference in permission requirements between TRX and TRC20 signature validation?
  • Could this be related to TRON's account permission model or multisig features?
  • Are there specific requirements for TRC20 smart contract transaction signing that differ from native transfers?

Cross-References

Also investigating on:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions