Package org.bitcoinj.crypto

Examples of org.bitcoinj.crypto.DeterministicKey.signMessage()


    @Nullable
    public String signAsOwner(PledgingWallet wallet, String message, @Nullable KeyParameter aesKey) {
        DeterministicKey realKey = wallet.getAuthKeyFromIndexOrPubKey(authKey, authKeyIndex);
        if (realKey == null || (aesKey == null && realKey.isEncrypted()))
            return null;
        return realKey.signMessage(message, aesKey);
    }

    public void authenticateOwner(String message, String signatureBase64) throws SignatureException {
        ECKey.fromPublicOnly(authKey).verifyMessage(message, signatureBase64);
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.