You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
New methods need to be added to the SDK in order to streamline account key specifications with considerations for alias.
The following APIs need to be added in AccountCreateTransaction:
setKeyWithAlias(ECDSAKey) - Sets ECDSA private key, derives and sets it's EVM address in the background. Essentially does setKey(Key) + setAlias(Alias)
setKeyWithAlias(Key, ECDSAKey) - Allows for setting the account key and a separate key that the EVM address should be derived from. A user must sign the transaction with both keys for this flow to be successful.
setKeyWithoutAlias(Key) - Explicitly calls out that the alias is not set.
The following APIs need to be deprecated in AccountCreateTransaction:
setKey(Key)
Test plan
When an account is created with an ECDSA key with setKeyWithAlias , then the created account has the ECDSA key as its key and the ECDSA key as its alias.
When an account is created with a Key and an ECDSA key with setKeyWithAlias, then the created account has the Key as its key and the ECDSA key as its alias.
When an account is created with a Key with setKeyWithoutAlias, then the created account has the Key as its key and no alias.
Example
Create an account with an ECDSA key using setKeyWithAlias .
Query the account and verify its key and alias match the ECDSA key.
Create another account with a Key and an ECDSA key using setKeyWithAlias .
Query the account and verify its key matches the Key and its alias matched the ECDSA key.
Create another account with a Key using setKeyWithoutAlias.
Query the account and verify its key matches the Key and it has no alias.
The text was updated successfully, but these errors were encountered:
Description
New methods need to be added to the SDK in order to streamline account key specifications with considerations for alias.
The following APIs need to be added in
AccountCreateTransaction
:setKeyWithAlias(ECDSAKey)
- Sets ECDSA private key, derives and sets it's EVM address in the background. Essentially doessetKey(Key)
+setAlias(Alias)
setKeyWithAlias(Key, ECDSAKey)
- Allows for setting the account key and a separate key that the EVM address should be derived from. A user must sign the transaction with both keys for this flow to be successful.setKeyWithoutAlias(Key)
- Explicitly calls out that the alias is not set.The following APIs need to be deprecated in
AccountCreateTransaction
:setKey(Key)
Test plan
setKeyWithAlias
, then the created account has the ECDSA key as its key and the ECDSA key as its alias.setKeyWithAlias
, then the created account has the Key as its key and the ECDSA key as its alias.setKeyWithoutAlias
, then the created account has the Key as its key and no alias.Example
setKeyWithAlias
.Key
and an ECDSA key usingsetKeyWithAlias
.Key
and its alias matched the ECDSA key.Key
usingsetKeyWithoutAlias
.Key
and it has no alias.The text was updated successfully, but these errors were encountered: