Skip to content

Commit

Permalink
Fix BouncyCastle issue tat was slowing things down
Browse files Browse the repository at this point in the history
  • Loading branch information
benjaminion committed Oct 7, 2019
1 parent 8273de1 commit a4e9cb1
Showing 1 changed file with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,10 @@

import java.math.BigInteger;
import java.nio.charset.StandardCharsets;
import java.security.Security;
import org.apache.milagro.amcl.BLS381.BIG;
import org.apache.milagro.amcl.BLS381.ROM;
import org.apache.tuweni.bytes.Bytes;
import org.apache.tuweni.crypto.Hash;
import org.bouncycastle.jce.provider.BouncyCastleProvider;

public class Helper {

Expand Down Expand Up @@ -184,8 +182,6 @@ static boolean onCurveG2(JacobianPoint p) {
*/
static Bytes HMAC_SHA256(byte[] text, byte[] key) {

Security.addProvider(new BouncyCastleProvider());

// SHA256 blocksize in bytes
int blockSize = SHA256_BLOCK_SIZE;
byte ipad = (byte) 0x36;
Expand Down

0 comments on commit a4e9cb1

Please sign in to comment.