use of org.fisco.bcos.web3j.crypto.gm.sm2.SM2Sign in project web3sdk by FISCO-BCOS.
the class EncryptType method setEncryptInterface.
private static void setEncryptInterface(int encryptType) {
SignInterface signInterface;
HashInterface hashInterface;
if (encryptType == SM2_TYPE) {
signInterface = new SM2Sign();
hashInterface = new SM3Digest();
} else {
signInterface = new ECDSASign();
hashInterface = new SHA3Digest();
}
Sign.setSignInterface(signInterface);
Hash.setHashInterface(hashInterface);
}