forked from Qortal/qortal
Update uses of old Public/PrivateKeyAccount static methods to Crypto
This commit is contained in:
parent
b262044a52
commit
bd543a526b
@ -945,7 +945,7 @@ public class Block {
|
||||
if (onlineAccounts.remove(onlineAccountData)) // remove() is like contains() but also reduces the number to check next time
|
||||
continue;
|
||||
|
||||
if (!PublicKeyAccount.verify(publicKey, signature, onlineTimestampBytes))
|
||||
if (!Crypto.verify(publicKey, signature, onlineTimestampBytes))
|
||||
return ValidationResult.ONLINE_ACCOUNT_SIGNATURE_INCORRECT;
|
||||
}
|
||||
|
||||
|
@ -169,7 +169,7 @@ public class ChatTransaction extends Transaction {
|
||||
throw new RuntimeException("Unable to transform transaction to byte array for verification", e);
|
||||
}
|
||||
|
||||
if (!PublicKeyAccount.verify(this.transactionData.getCreatorPublicKey(), signature, transactionBytes))
|
||||
if (!Crypto.verify(this.transactionData.getCreatorPublicKey(), signature, transactionBytes))
|
||||
return false;
|
||||
|
||||
int nonce = this.chatTransactionData.getNonce();
|
||||
|
@ -18,6 +18,7 @@ import org.qortal.account.PublicKeyAccount;
|
||||
import org.qortal.asset.Asset;
|
||||
import org.qortal.block.BlockChain;
|
||||
import org.qortal.controller.Controller;
|
||||
import org.qortal.crypto.Crypto;
|
||||
import org.qortal.data.block.BlockData;
|
||||
import org.qortal.data.group.GroupApprovalData;
|
||||
import org.qortal.data.group.GroupData;
|
||||
@ -479,7 +480,7 @@ public abstract class Transaction {
|
||||
return false;
|
||||
|
||||
try {
|
||||
return PublicKeyAccount.verify(this.transactionData.getCreatorPublicKey(), signature, TransactionTransformer.toBytesForSigning(transactionData));
|
||||
return Crypto.verify(this.transactionData.getCreatorPublicKey(), signature, TransactionTransformer.toBytesForSigning(transactionData));
|
||||
} catch (TransformationException e) {
|
||||
throw new RuntimeException("Unable to transform transaction to byte array for verification", e);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user