throw new MissingPrivateKeyException();
check(priv != null, "Private key must not be null");
ECDSASigner signer = new ECDSASigner(new HMacDSAKCalculator(new SHA256Digest()));
ECPrivateKeyParameters privKey = new ECPrivateKeyParameters(priv, CURVE);
signer.init(true, privKey);
BigInteger[] components = signer.generateSignature(input);
return new ECDSASignature(components[0], components[1]).toCanonicalised();
}
/**
* Takes the sha3 hash (32 bytes) of data and returns the ECDSA signature