chunkView Unmarshal exception
Closed this issue · 1 comments
vic-dayou commented
The main network blcok 70249973 already supports secp256k1 algorithm,
but sdk still does not support it, currently chunkView Unmarshal exception。
func WrapRawKey(keyType PublicKeyType, key []byte) (pk PublicKey, err error) {
switch keyType {
case KeyTypeED25519:
if len(key) != ed25519.PublicKeySize {
return pk, ErrInvalidPublicKey
}
pk[0] = RawKeyTypeED25519
copy(pk[1:], key[0:ed25519.PublicKeySize])
return
case KeyTypeSECP256K1:
// TODO!
return pk, fmt.Errorf("SECP256K1 is not supported yet")
}
return pk, ErrInvalidKeyType
}
mikroskeem commented
Should be solved by #30. Can you confirm if this works for you?