Blockchain Account Id
A specification to store wallet address of multiple chain on Hypersign DID
EIP-155 - Identifying a blockchain within Ethereum ecosystem
ChainID was introduced in EIP-155 to prevent replay attacks between the main ETH and ETC chain since they both have same networkID 1
. Its an additional way to tell the chains are apart. So, now due to EIP-155, ETH has a chainId 1
whereas ETC has a chainID of 61
. (see chainlist here)
What is replay attack?
In EVM ecosystem, same account address can be used in multiple chains. Hence it was possible to send same transactions on multiple chains - hence the term replay attack. For example, it is possible to issue a fund transferon a testchain and then perform same transfer on Mainnet. This vulnerability is because that the same account (corresponding to same private key) can exists in any EVM chains.
Specification
To fix this issue Ethereum allowed insertions of ChainID data in the signed transaction.
So earlier we generated transaction hash using these values:
But now, we will generate transaction hash using these values:
CAIP-2 - Identifying a blockchain in any ecosystem
Its a way to identify different blockchains (e.g. Ethereum Mainnet, Cosmos hub, Bitcoin etc) in developer-friendly manner.
We often need to reference a blockchain to state where some asset like token or smart contract is located. In Ethereum the EIP-155 chain ID is used most of the time but with Ethereum Chain ID, you can not reference other blockchains like Bitcoin or Cosmos.
Specification:
E.g:
CAIP-10 - Identifying a walletaddress in any ecosystem
CAIP-10 extends CAIP-2 to the account level. This specification facilitate specifying accounts for any blockchains. Its chain-agnostic protocol for that was independent of any blockchain but provide the flexibility to be backwards compatible with existing applications.
It is useful for both decentralized applications (dApps) and wallets to communicate user accounts for multiple chains using string identifiers specific to each chain.
Specification:
The account_id
is a case-sensitive string in the form
E.g:
CAIP-2 describes blockchain Id whereas CAIP-10 describes account Id
BlockchainAccountId
blockchainAccountId
field or property of verification method in Hypersign DID, is used to specify a blockchain account id as per CAIP-10 specification.
Supported Chains
TODO: Add list of supported chains by Hypersign
Example of EVM based wallet address
TODO: Give one example of EVM based wallet
Example of Cosmos based wallet address
TODO: Give one example of EVM based wallet
Last updated