accounts/keystore, crypto: don't enforce key checks on existing keyfiles

This commit is contained in:
Péter Szilágyi
2017-06-01 10:24:40 +03:00
parent 067dc2cbf5
commit 72dd51e25a
4 changed files with 25 additions and 17 deletions

View File

@ -182,10 +182,8 @@ func DecryptKey(keyjson []byte, auth string) (*Key, error) {
if err != nil {
return nil, err
}
key, err := crypto.ToECDSA(keyBytes)
if err != nil {
return nil, err
}
key := crypto.ToECDSAUnsafe(keyBytes)
return &Key{
Id: uuid.UUID(keyId),
Address: crypto.PubkeyToAddress(key.PublicKey),