Skip to content

package "orchestration" src/utils/address.js should fully conform with CAIP-10 #12186

@gibson042

Description

@gibson042

What

parseAccountId requires just 3 colon-separated parts, but CAIP-10 is much stricter:

account_id:        chain_id + ":" + account_address
chain_id:          [-a-z0-9]{3,8}:[-_a-zA-Z0-9]{1,32} (See [CAIP-2][])
account_address:   [-.%a-zA-Z0-9]{1,128}

For an already worked example, see 34667cf (written before packages/orchestration/src/utils/address.js was pointed out to me).

Note that this will likely require updating test examples to be compliant.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions