From f5410bedf4b0f68e602d86ab754cdb016f52c399 Mon Sep 17 00:00:00 2001 From: Tal Moran Date: Tue, 5 Apr 2016 11:51:01 +0300 Subject: [PATCH] Typo fixes --- mixer/src/test/java/mixer/CreateTestVector.java | 4 ++-- .../mixer/{MixingText.java => MixingTest.java} | 6 +++--- mixer/src/test/java/mixer/RerandomizeTest.java | 8 ++++---- .../test/java/mixer/{Utiles.java => Utils.java} | 2 +- .../test/java/mixer/ZeroKnowledgeProofTest.java | 14 +++++++------- .../src/test/java/profiling/BigInteger/AddSub.java | 4 ++-- .../profiling/BigInteger/GenerateRandomness.java | 4 ++-- .../src/test/java/profiling/BigInteger/Modulo.java | 4 ++-- mixer/src/test/java/profiling/BigInteger/Mul.java | 4 ++-- .../java/profiling/Convert/ByteString2ECPoint.java | 6 +++--- ...omizableEncryptedMessage2ElGamalCiphertext.java | 6 +++--- mixer/src/test/java/profiling/ECGroup/Add.java | 4 ++-- mixer/src/test/java/profiling/ECGroup/Encode.java | 4 ++-- mixer/src/test/java/profiling/ECGroup/Mul.java | 4 ++-- mixer/src/test/java/profiling/ECGroup/Negate.java | 4 ++-- mixer/src/test/java/profiling/Rerandomize.java | 6 +++--- .../test/java/profiling/ZeroKnowledgeProof.java | 6 +++--- 17 files changed, 45 insertions(+), 45 deletions(-) rename mixer/src/test/java/mixer/{MixingText.java => MixingTest.java} (93%) rename mixer/src/test/java/mixer/{Utiles.java => Utils.java} (99%) diff --git a/mixer/src/test/java/mixer/CreateTestVector.java b/mixer/src/test/java/mixer/CreateTestVector.java index 591b397..ed43995 100644 --- a/mixer/src/test/java/mixer/CreateTestVector.java +++ b/mixer/src/test/java/mixer/CreateTestVector.java @@ -43,7 +43,7 @@ public class CreateTestVector { random = new Random(); group = new ECGroup("secp256k1"); encryptor = new ECElGamalEncryption(); - encryptor.init(Utiles.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); + encryptor.init(Utils.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); randomMixer = new Random(); randomProver = new Random(); randomOracle = new DigestOracle(); @@ -61,7 +61,7 @@ public class CreateTestVector { List result = new ArrayList(); Voting.PlaintextBallot msg; for (int i = 0; i < n ; i++){ - msg = Utiles.genRandomBallot(2,3,16); + msg = Utils.genRandomBallot(2,3,16); result.add(encryptor.encrypt(msg, encryptor.generateRandomness(random))); } return result; diff --git a/mixer/src/test/java/mixer/MixingText.java b/mixer/src/test/java/mixer/MixingTest.java similarity index 93% rename from mixer/src/test/java/mixer/MixingText.java rename to mixer/src/test/java/mixer/MixingTest.java index dc003be..63f6426 100644 --- a/mixer/src/test/java/mixer/MixingText.java +++ b/mixer/src/test/java/mixer/MixingTest.java @@ -24,7 +24,7 @@ import java.util.ArrayList; import java.util.List; import java.util.Random; -public class MixingText { +public class MixingTest { ECElGamalEncryption encryptor; ECGroup group; @@ -43,7 +43,7 @@ public class MixingText { random = new Random(); group = new ECGroup("secp256k1"); encryptor = new ECElGamalEncryption(); - encryptor.init(Utiles.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); + encryptor.init(Utils.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); randomMixer = new Random(); randomProver = new Random(); randomOracle = new DigestOracle(); @@ -61,7 +61,7 @@ public class MixingText { List result = new ArrayList(); Voting.PlaintextBallot msg; for (int i = 0; i < n ; i++){ - msg = Utiles.genRandomBallot(2,3,16); + msg = Utils.genRandomBallot(2,3,16); result.add(encryptor.encrypt(msg, encryptor.generateRandomness(random))); } return result; diff --git a/mixer/src/test/java/mixer/RerandomizeTest.java b/mixer/src/test/java/mixer/RerandomizeTest.java index 66b0343..034e311 100644 --- a/mixer/src/test/java/mixer/RerandomizeTest.java +++ b/mixer/src/test/java/mixer/RerandomizeTest.java @@ -35,7 +35,7 @@ public class RerandomizeTest { group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); key = new ECElGamal.SK(group, sk); - serializedPk = Utiles.serializePk(group, key); + serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); RandomOracle randomOracle = new DigestOracle(); @@ -48,7 +48,7 @@ public class RerandomizeTest { } public void oneRerandomizeTest() throws InvalidProtocolBufferException { - Voting.PlaintextBallot msg = Utiles.genRandomBallot(2,3,16); // 2 questions with 3 answers each, in range 0-15. + Voting.PlaintextBallot msg = Utils.genRandomBallot(2,3,16); // 2 questions with 3 answers each, in range 0-15. Crypto.EncryptionRandomness r = enc.generateRandomness(rand); @@ -56,8 +56,8 @@ public class RerandomizeTest { Crypto.RerandomizableEncryptedMessage e = enc.encrypt(msg, enc.generateRandomness(rand)); Crypto.RerandomizableEncryptedMessage eNew = enc.rerandomize(e, r); - assert (Utiles.decrypt(Voting.PlaintextBallot.class, key, group, e).equals(msg)); - assert (Utiles.decrypt(Voting.PlaintextBallot.class, key, group, eNew).equals(msg)); + assert (Utils.decrypt(Voting.PlaintextBallot.class, key, group, e).equals(msg)); + assert (Utils.decrypt(Voting.PlaintextBallot.class, key, group, eNew).equals(msg)); ConcreteCrypto.ElGamalCiphertext eElGamal = ECElGamalEncryption.RerandomizableEncryptedMessage2ElGamalCiphertext(e); ConcreteCrypto.ElGamalCiphertext eNewElGamal = ECElGamalEncryption.RerandomizableEncryptedMessage2ElGamalCiphertext(eNew); diff --git a/mixer/src/test/java/mixer/Utiles.java b/mixer/src/test/java/mixer/Utils.java similarity index 99% rename from mixer/src/test/java/mixer/Utiles.java rename to mixer/src/test/java/mixer/Utils.java index 0bb0e36..78e789e 100644 --- a/mixer/src/test/java/mixer/Utiles.java +++ b/mixer/src/test/java/mixer/Utils.java @@ -26,7 +26,7 @@ import java.util.Random; /** * Created by Tzlil on 1/1/2016. */ -public class Utiles { +public class Utils { public final static String ENCRYPTION_KEY_ALGORITHM = "ECDH"; diff --git a/mixer/src/test/java/mixer/ZeroKnowledgeProofTest.java b/mixer/src/test/java/mixer/ZeroKnowledgeProofTest.java index 4e9b404..413fbc8 100644 --- a/mixer/src/test/java/mixer/ZeroKnowledgeProofTest.java +++ b/mixer/src/test/java/mixer/ZeroKnowledgeProofTest.java @@ -40,7 +40,7 @@ public class ZeroKnowledgeProofTest { group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); key = new ECElGamal.SK(group, sk); - serializedPk = Utiles.serializePk(group, key); + serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); RandomOracle randomOracle = new DigestOracle(); @@ -53,8 +53,8 @@ public class ZeroKnowledgeProofTest { } public void oneZKPTest() throws InvalidProtocolBufferException { - Voting.PlaintextBallot msg1 = Utiles.genRandomBallot(2,3,16); // 2 questions with 3 answers each, in range 0-15. - Voting.PlaintextBallot msg2 = Utiles.genRandomBallot(2,3,16); + Voting.PlaintextBallot msg1 = Utils.genRandomBallot(2,3,16); // 2 questions with 3 answers each, in range 0-15. + Voting.PlaintextBallot msg2 = Utils.genRandomBallot(2,3,16); Crypto.EncryptionRandomness r1 = enc.generateRandomness(rand); Crypto.EncryptionRandomness r2 = enc.generateRandomness(rand); @@ -63,10 +63,10 @@ public class ZeroKnowledgeProofTest { Crypto.RerandomizableEncryptedMessage e1New = enc.rerandomize(e1, r1); Crypto.RerandomizableEncryptedMessage e2New = enc.rerandomize(e2, r2); - assert (Utiles.decrypt(Voting.PlaintextBallot.class, key, group, e1).equals(msg1)); - assert (Utiles.decrypt(Voting.PlaintextBallot.class, key, group, e1New).equals(msg1)); - assert (Utiles.decrypt(Voting.PlaintextBallot.class, key, group, e2).equals(msg2)); - assert (Utiles.decrypt(Voting.PlaintextBallot.class, key, group, e2New).equals(msg2)); + assert (Utils.decrypt(Voting.PlaintextBallot.class, key, group, e1).equals(msg1)); + assert (Utils.decrypt(Voting.PlaintextBallot.class, key, group, e1New).equals(msg1)); + assert (Utils.decrypt(Voting.PlaintextBallot.class, key, group, e2).equals(msg2)); + assert (Utils.decrypt(Voting.PlaintextBallot.class, key, group, e2New).equals(msg2)); ECPoint g = group.getGenerator(); ECPoint h = enc.getElGamalPK().getPK(); diff --git a/mixer/src/test/java/profiling/BigInteger/AddSub.java b/mixer/src/test/java/profiling/BigInteger/AddSub.java index b7cca3f..19474f7 100644 --- a/mixer/src/test/java/profiling/BigInteger/AddSub.java +++ b/mixer/src/test/java/profiling/BigInteger/AddSub.java @@ -3,7 +3,7 @@ package profiling.BigInteger; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; -import mixer.Utiles; +import mixer.Utils; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -28,7 +28,7 @@ public class AddSub { ECGroup group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); ECElGamal.SK key = new ECElGamal.SK(group, sk); - ConcreteCrypto.ElGamalPublicKey serializedPk = Utiles.serializePk(group, key); + ConcreteCrypto.ElGamalPublicKey serializedPk = Utils.serializePk(group, key); ECElGamalEncryption enc = new ECElGamalEncryption(); enc.init(serializedPk); diff --git a/mixer/src/test/java/profiling/BigInteger/GenerateRandomness.java b/mixer/src/test/java/profiling/BigInteger/GenerateRandomness.java index 8711ab4..e003dea 100644 --- a/mixer/src/test/java/profiling/BigInteger/GenerateRandomness.java +++ b/mixer/src/test/java/profiling/BigInteger/GenerateRandomness.java @@ -3,7 +3,7 @@ package profiling.BigInteger; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; -import mixer.Utiles; +import mixer.Utils; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -25,7 +25,7 @@ public class GenerateRandomness { BigInteger sk = ECElGamal.generateSecretKey(group, rand); ECElGamal.SK key = new ECElGamal.SK(group, sk); - ConcreteCrypto.ElGamalPublicKey serializedPk = Utiles.serializePk(group, key); + ConcreteCrypto.ElGamalPublicKey serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); diff --git a/mixer/src/test/java/profiling/BigInteger/Modulo.java b/mixer/src/test/java/profiling/BigInteger/Modulo.java index 8d2a6b9..9443347 100644 --- a/mixer/src/test/java/profiling/BigInteger/Modulo.java +++ b/mixer/src/test/java/profiling/BigInteger/Modulo.java @@ -3,7 +3,7 @@ package profiling.BigInteger; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; -import mixer.Utiles; +import mixer.Utils; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -27,7 +27,7 @@ public class Modulo { BigInteger sk = ECElGamal.generateSecretKey(group, rand); ECElGamal.SK key = new ECElGamal.SK(group, sk); - ConcreteCrypto.ElGamalPublicKey serializedPk = Utiles.serializePk(group, key); + ConcreteCrypto.ElGamalPublicKey serializedPk = Utils.serializePk(group, key); ECElGamalEncryption enc = new ECElGamalEncryption(); enc.init(serializedPk); for (int i =0 ; i < tests ; i++){ diff --git a/mixer/src/test/java/profiling/BigInteger/Mul.java b/mixer/src/test/java/profiling/BigInteger/Mul.java index b7d8730..dfb8090 100644 --- a/mixer/src/test/java/profiling/BigInteger/Mul.java +++ b/mixer/src/test/java/profiling/BigInteger/Mul.java @@ -3,7 +3,7 @@ package profiling.BigInteger; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; -import mixer.Utiles; +import mixer.Utils; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -28,7 +28,7 @@ public class Mul { ECGroup group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); ECElGamal.SK key = new ECElGamal.SK(group, sk); - ConcreteCrypto.ElGamalPublicKey serializedPk = Utiles.serializePk(group, key); + ConcreteCrypto.ElGamalPublicKey serializedPk = Utils.serializePk(group, key); ECElGamalEncryption enc = new ECElGamalEncryption(); enc.init(serializedPk); diff --git a/mixer/src/test/java/profiling/Convert/ByteString2ECPoint.java b/mixer/src/test/java/profiling/Convert/ByteString2ECPoint.java index 931e0e3..92b0c3f 100644 --- a/mixer/src/test/java/profiling/Convert/ByteString2ECPoint.java +++ b/mixer/src/test/java/profiling/Convert/ByteString2ECPoint.java @@ -5,7 +5,7 @@ import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; import meerkat.protobuf.Voting; -import mixer.Utiles; +import mixer.Utils; import org.bouncycastle.math.ec.ECPoint; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -30,7 +30,7 @@ public class ByteString2ECPoint { group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); key = new ECElGamal.SK(group, sk); - serializedPk = Utiles.serializePk(group, key); + serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); tests = 1024 * 19; @@ -39,7 +39,7 @@ public class ByteString2ECPoint { Voting.PlaintextBallot msg; for (int i = 0; i < tests; i ++){ - msg = Utiles.genRandomBallot(2,3,16); + msg = Utils.genRandomBallot(2,3,16); encryptedMessage[i] = ECElGamalEncryption.RerandomizableEncryptedMessage2ElGamalCiphertext (enc.encrypt(msg, enc.generateRandomness(rand))); diff --git a/mixer/src/test/java/profiling/Convert/RerandomizableEncryptedMessage2ElGamalCiphertext.java b/mixer/src/test/java/profiling/Convert/RerandomizableEncryptedMessage2ElGamalCiphertext.java index 18625d0..3473430 100644 --- a/mixer/src/test/java/profiling/Convert/RerandomizableEncryptedMessage2ElGamalCiphertext.java +++ b/mixer/src/test/java/profiling/Convert/RerandomizableEncryptedMessage2ElGamalCiphertext.java @@ -5,7 +5,7 @@ import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; import meerkat.protobuf.Crypto; import meerkat.protobuf.Voting; -import mixer.Utiles; +import mixer.Utils; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -29,7 +29,7 @@ public class RerandomizableEncryptedMessage2ElGamalCiphertext { group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); key = new ECElGamal.SK(group, sk); - serializedPk = Utiles.serializePk(group, key); + serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); tests = 1024 * 18; @@ -38,7 +38,7 @@ public class RerandomizableEncryptedMessage2ElGamalCiphertext { Voting.PlaintextBallot msg; for (int i = 0; i < tests; i ++){ - msg = Utiles.genRandomBallot(2,3,16); + msg = Utils.genRandomBallot(2,3,16); encryptedMessage[i] = enc.encrypt(msg, enc.generateRandomness(rand)); } diff --git a/mixer/src/test/java/profiling/ECGroup/Add.java b/mixer/src/test/java/profiling/ECGroup/Add.java index ceadc43..a1cbdfb 100644 --- a/mixer/src/test/java/profiling/ECGroup/Add.java +++ b/mixer/src/test/java/profiling/ECGroup/Add.java @@ -2,7 +2,7 @@ package profiling.ECGroup; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; -import mixer.Utiles; +import mixer.Utils; import org.bouncycastle.math.ec.ECPoint; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -29,7 +29,7 @@ public class Add { random = new Random(); group = new ECGroup("secp256k1"); encryptor = new ECElGamalEncryption(); - encryptor.init(Utiles.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); + encryptor.init(Utils.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); // generate n; int sqrtn = 128; n = sqrtn*sqrtn; diff --git a/mixer/src/test/java/profiling/ECGroup/Encode.java b/mixer/src/test/java/profiling/ECGroup/Encode.java index 57db853..d9577d7 100644 --- a/mixer/src/test/java/profiling/ECGroup/Encode.java +++ b/mixer/src/test/java/profiling/ECGroup/Encode.java @@ -2,7 +2,7 @@ package profiling.ECGroup; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; -import mixer.Utiles; +import mixer.Utils; import org.bouncycastle.math.ec.ECPoint; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -29,7 +29,7 @@ public class Encode { random = new Random(); group = new ECGroup("secp256k1"); encryptor = new ECElGamalEncryption(); - encryptor.init(Utiles.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); + encryptor.init(Utils.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); // generate n; int sqrtn = 128; n = sqrtn*sqrtn; diff --git a/mixer/src/test/java/profiling/ECGroup/Mul.java b/mixer/src/test/java/profiling/ECGroup/Mul.java index f59bf68..2a5573a 100644 --- a/mixer/src/test/java/profiling/ECGroup/Mul.java +++ b/mixer/src/test/java/profiling/ECGroup/Mul.java @@ -2,7 +2,7 @@ package profiling.ECGroup; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; -import mixer.Utiles; +import mixer.Utils; import org.bouncycastle.math.ec.ECPoint; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -30,7 +30,7 @@ public class Mul { random = new Random(); group = new ECGroup("secp256k1"); encryptor = new ECElGamalEncryption(); - encryptor.init(Utiles.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); + encryptor.init(Utils.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); // generate n int sqrtn = 128; n = sqrtn*sqrtn; diff --git a/mixer/src/test/java/profiling/ECGroup/Negate.java b/mixer/src/test/java/profiling/ECGroup/Negate.java index 91ee6e4..f5b6e15 100644 --- a/mixer/src/test/java/profiling/ECGroup/Negate.java +++ b/mixer/src/test/java/profiling/ECGroup/Negate.java @@ -2,7 +2,7 @@ package profiling.ECGroup; import com.google.protobuf.InvalidProtocolBufferException; import meerkat.crypto.concrete.ECElGamalEncryption; -import mixer.Utiles; +import mixer.Utils; import org.bouncycastle.math.ec.ECPoint; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -28,7 +28,7 @@ public class Negate { random = new Random(); group = new ECGroup("secp256k1"); encryptor = new ECElGamalEncryption(); - encryptor.init(Utiles.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); + encryptor.init(Utils.serializePk(group, new ECElGamal.SK(group, ECElGamal.generateSecretKey(group, random)))); // generate n; int sqrtn = 128; n = sqrtn*sqrtn; diff --git a/mixer/src/test/java/profiling/Rerandomize.java b/mixer/src/test/java/profiling/Rerandomize.java index 8e9ddb4..ea900b5 100644 --- a/mixer/src/test/java/profiling/Rerandomize.java +++ b/mixer/src/test/java/profiling/Rerandomize.java @@ -5,7 +5,7 @@ import meerkat.crypto.concrete.ECElGamalEncryption; import meerkat.protobuf.ConcreteCrypto; import meerkat.protobuf.Crypto; import meerkat.protobuf.Voting; -import mixer.Utiles; +import mixer.Utils; import org.factcenter.qilin.primitives.concrete.ECElGamal; import org.factcenter.qilin.primitives.concrete.ECGroup; @@ -31,7 +31,7 @@ public class Rerandomize { group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); key = new ECElGamal.SK(group, sk); - serializedPk = Utiles.serializePk(group, key); + serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); int LogVotes = 10; @@ -43,7 +43,7 @@ public class Rerandomize { Voting.PlaintextBallot msg; for (int i = 0; i < n ; i ++){ - msg = Utiles.genRandomBallot(2,3,16); + msg = Utils.genRandomBallot(2,3,16); randomnesses[i] = enc.generateRandomness(rand); encryptedMessage[i] = enc.encrypt(msg, enc.generateRandomness(rand)); } diff --git a/mixer/src/test/java/profiling/ZeroKnowledgeProof.java b/mixer/src/test/java/profiling/ZeroKnowledgeProof.java index dcacd0d..fe1d407 100644 --- a/mixer/src/test/java/profiling/ZeroKnowledgeProof.java +++ b/mixer/src/test/java/profiling/ZeroKnowledgeProof.java @@ -7,7 +7,7 @@ import meerkat.crypto.mixnet.Mix2ZeroKnowledgeProver; import meerkat.protobuf.ConcreteCrypto; import meerkat.protobuf.Crypto; import meerkat.protobuf.Voting; -import mixer.Utiles; +import mixer.Utils; import org.bouncycastle.math.ec.ECPoint; import org.factcenter.qilin.primitives.RandomOracle; import org.factcenter.qilin.primitives.concrete.DigestOracle; @@ -39,7 +39,7 @@ public class ZeroKnowledgeProof { group = new ECGroup("secp256k1"); BigInteger sk = ECElGamal.generateSecretKey(group, rand); key = new ECElGamal.SK(group, sk); - serializedPk = Utiles.serializePk(group, key); + serializedPk = Utils.serializePk(group, key); enc = new ECElGamalEncryption(); enc.init(serializedPk); RandomOracle randomOracle = new DigestOracle(); @@ -55,7 +55,7 @@ public class ZeroKnowledgeProof { for (int i = 0; i < n*2 ; i ++){ - msg = Utiles.genRandomBallot(2,3,16); + msg = Utils.genRandomBallot(2,3,16); randomnesses[i] = enc.generateRandomness(rand); encryptedMessage[i] = enc.encrypt(msg, enc.generateRandomness(rand)); reencryptedMessage[i] = enc.rerandomize(encryptedMessage[i], randomnesses[i]);