package renaming and protobuf moves

DKG
Tal Moran 2016-04-11 19:48:36 +03:00
parent d0951f8644
commit 1ec02173e7
59 changed files with 148 additions and 150 deletions

View File

@ -2,8 +2,8 @@ package meerkat.bulletinboard;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.comm.CommunicationException; import meerkat.comm.CommunicationException;
import meerkat.destributed_key_generation.Digest; import meerkat.crypto.Digest;
import meerkat.destributed_key_generation.concrete.SHA256Digest; import meerkat.crypto.concrete.SHA256Digest;
import meerkat.protobuf.BulletinBoardAPI.*; import meerkat.protobuf.BulletinBoardAPI.*;
import meerkat.rest.Constants; import meerkat.rest.Constants;
import meerkat.rest.ProtobufMessageBodyReader; import meerkat.rest.ProtobufMessageBodyReader;

View File

@ -2,8 +2,8 @@ package meerkat.bulletinboard;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import meerkat.comm.CommunicationException; import meerkat.comm.CommunicationException;
import meerkat.destributed_key_generation.Digest; import meerkat.crypto.Digest;
import meerkat.destributed_key_generation.concrete.SHA256Digest; import meerkat.crypto.concrete.SHA256Digest;
import meerkat.protobuf.BulletinBoardAPI.*; import meerkat.protobuf.BulletinBoardAPI.*;
import meerkat.protobuf.Voting; import meerkat.protobuf.Voting;
import meerkat.protobuf.Voting.BulletinBoardClientParams; import meerkat.protobuf.Voting.BulletinBoardClientParams;

View File

@ -6,8 +6,8 @@ import meerkat.bulletinboard.callbacks.GetRedundancyFutureCallback;
import meerkat.bulletinboard.callbacks.PostMessageFutureCallback; import meerkat.bulletinboard.callbacks.PostMessageFutureCallback;
import meerkat.bulletinboard.callbacks.ReadMessagesFutureCallback; import meerkat.bulletinboard.callbacks.ReadMessagesFutureCallback;
import meerkat.comm.CommunicationException; import meerkat.comm.CommunicationException;
import meerkat.destributed_key_generation.Digest; import meerkat.crypto.Digest;
import meerkat.destributed_key_generation.concrete.SHA256Digest; import meerkat.crypto.concrete.SHA256Digest;
import meerkat.protobuf.BulletinBoardAPI.*; import meerkat.protobuf.BulletinBoardAPI.*;
import meerkat.protobuf.Voting; import meerkat.protobuf.Voting;

View File

@ -13,8 +13,8 @@ import meerkat.comm.CommunicationException;
import meerkat.protobuf.BulletinBoardAPI.*; import meerkat.protobuf.BulletinBoardAPI.*;
import meerkat.protobuf.Crypto.Signature; import meerkat.protobuf.Crypto.Signature;
import meerkat.protobuf.Crypto.SignatureVerificationKey; import meerkat.protobuf.Crypto.SignatureVerificationKey;
import meerkat.destributed_key_generation.Digest; import meerkat.crypto.Digest;
import meerkat.destributed_key_generation.concrete.SHA256Digest; import meerkat.crypto.concrete.SHA256Digest;
import javax.sql.DataSource; import javax.sql.DataSource;

View File

@ -18,7 +18,7 @@ import java.util.Random;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import meerkat.comm.CommunicationException; import meerkat.comm.CommunicationException;
import meerkat.destributed_key_generation.concrete.ECDSASignature; import meerkat.crypto.concrete.ECDSASignature;
import meerkat.protobuf.BulletinBoardAPI.BulletinBoardMessage; import meerkat.protobuf.BulletinBoardAPI.BulletinBoardMessage;
import meerkat.protobuf.BulletinBoardAPI.FilterType; import meerkat.protobuf.BulletinBoardAPI.FilterType;
import meerkat.protobuf.BulletinBoardAPI.MessageFilter; import meerkat.protobuf.BulletinBoardAPI.MessageFilter;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.communication; package meerkat.crypto.dkg.comm;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
/** /**

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.communication; package meerkat.crypto.dkg.comm;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,15 +1,15 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import com.google.protobuf.InvalidProtocolBufferException; import com.google.protobuf.InvalidProtocolBufferException;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.destributed_key_generation.concrete.distributed_key_generation.communication.MessageHandler; import meerkat.crypto.dkg.comm.MessageHandler;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
/** /**
* Created by Tzlil on 2/29/2016. * Created by Tzlil on 2/29/2016.
* an extension of MailHandler matching joint feldman protocol * an extension of MailHandler matching joint feldman protocol
*/ */
public class MailHandler extends meerkat.destributed_key_generation.concrete.distributed_key_generation.communication.MailHandler { public class MailHandler extends meerkat.crypto.dkg.comm.MailHandler {
/** /**
* constructor * constructor

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Arrays; import java.util.Arrays;

View File

@ -1,8 +1,8 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.destributed_key_generation.concrete.secret_shring.feldman_verifiable.VerifiableSecretSharing; import meerkat.crypto.secretsharing.feldman.VerifiableSecretSharing;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
import org.factcenter.qilin.primitives.Group; import org.factcenter.qilin.primitives.Group;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
@ -59,7 +59,7 @@ public class User<T> implements Runnable{
/** /**
* mail handler registered to channel as ReceiverCallback * mail handler registered to channel as ReceiverCallback
*/ */
protected meerkat.destributed_key_generation.concrete.distributed_key_generation.communication.MailHandler mailHandler; protected meerkat.crypto.dkg.comm.MailHandler mailHandler;
/** /**
* channel object * channel object
@ -360,7 +360,7 @@ public class User<T> implements Runnable{
/** /**
* an implementation of MessageHandler * an implementation of MessageHandler
*/ */
public class MessageHandler implements meerkat.destributed_key_generation.concrete.distributed_key_generation.communication.MessageHandler{ public class MessageHandler implements meerkat.crypto.dkg.comm.MessageHandler{
/** /**
* commitment message is valid if: * commitment message is valid if:

View File

@ -1,15 +1,15 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import com.google.protobuf.InvalidProtocolBufferException; import com.google.protobuf.InvalidProtocolBufferException;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.destributed_key_generation.concrete.distributed_key_generation.communication.MessageHandler; import meerkat.crypto.dkg.comm.MessageHandler;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
/** /**
* Created by Tzlil on 2/29/2016. * Created by Tzlil on 2/29/2016.
* an extension of MailHandler matching gjkr protocl * an extension of MailHandler matching gjkr protocl
*/ */
public class MailHandler extends meerkat.destributed_key_generation.concrete.distributed_key_generation.communication.MailHandler { public class MailHandler extends meerkat.crypto.dkg.comm.MailHandler {
/** /**
* flag that indicants whether the * flag that indicants whether the

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashSet; import java.util.HashSet;
@ -13,7 +13,7 @@ import java.util.Set;
* contains all relevant information on specific party during * contains all relevant information on specific party during
* the run of the safe protocol * the run of the safe protocol
*/ */
public class Party<T> extends meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.Party<T> { public class Party<T> extends meerkat.crypto.dkg.feldman.Party<T> {
public Polynomial.Point shareT; public Polynomial.Point shareT;
public boolean ysDoneFlag; public boolean ysDoneFlag;
public ArrayList<T> verifiableValues; public ArrayList<T> verifiableValues;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import meerkat.destributed_key_generation.concrete.secret_shring.feldman_verifiable.VerifiableSecretSharing; import meerkat.crypto.secretsharing.feldman.VerifiableSecretSharing;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
import org.factcenter.qilin.primitives.Group; import org.factcenter.qilin.primitives.Group;
@ -17,7 +17,7 @@ import java.util.Set;
* TODO: comments * TODO: comments
* TODO: put Channel (ChannelImpl) in constructor * TODO: put Channel (ChannelImpl) in constructor
*/ */
public class Protocol<T> extends meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.Protocol<T> { public class Protocol<T> extends meerkat.crypto.dkg.feldman.Protocol<T> {
private VerifiableSecretSharing<T> maskingShares; private VerifiableSecretSharing<T> maskingShares;
private final T h; private final T h;

View File

@ -1,10 +1,10 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.concrete.Fp;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.SecretSharing; import meerkat.crypto.secretsharing.shamir.SecretSharing;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
@ -22,7 +22,7 @@ import java.util.ArrayList;
* as in joint feldman, each party in QUAL has his own share of the generated random key. * as in joint feldman, each party in QUAL has his own share of the generated random key.
* this key can be recover by any subset of QUAL of size at least t + 1. * this key can be recover by any subset of QUAL of size at least t + 1.
*/ */
public class User<T> extends meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.User<T> { public class User<T> extends meerkat.crypto.dkg.feldman.User<T> {
/** /**
* All parties participating in key generation. * All parties participating in key generation.
@ -190,7 +190,7 @@ public class User<T> extends meerkat.destributed_key_generation.concrete.distrib
super.stage4(); super.stage4();
} }
private class MessageHandler extends meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.User.MessageHandler { private class MessageHandler extends meerkat.crypto.dkg.feldman.User.MessageHandler {
boolean isStage4; boolean isStage4;
/** /**
@ -259,10 +259,10 @@ public class User<T> extends meerkat.destributed_key_generation.concrete.distrib
synchronized (parties[i - 1]) { synchronized (parties[i - 1]) {
if (!isStage4) { if (!isStage4) {
if (sdkg.isValidShare(secret, secretT, parties[j - 1].verifiableValues, i)) { if (sdkg.isValidShare(secret, secretT, parties[j - 1].verifiableValues, i)) {
parties[i - 1].complaints[j - 1] = meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.Protocol.ComplaintState.NonDisqualified; parties[i - 1].complaints[j - 1] = meerkat.crypto.dkg.feldman.Protocol.ComplaintState.NonDisqualified;
} else { } else {
parties[i - 1].complaints[j - 1] = meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.Protocol.ComplaintState.Disqualified; parties[i - 1].complaints[j - 1] = meerkat.crypto.dkg.feldman.Protocol.ComplaintState.Disqualified;
} }
if (j == id) { if (j == id) {
parties[i - 1].share = secret; parties[i - 1].share = secret;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.secret_shring.feldman_verifiable; package meerkat.crypto.secretsharing.feldman;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.SecretSharing; import meerkat.crypto.secretsharing.shamir.SecretSharing;
import org.factcenter.qilin.primitives.Group; import org.factcenter.qilin.primitives.Group;
import java.util.ArrayList; import java.util.ArrayList;

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir; package meerkat.crypto.secretsharing.shamir;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import java.math.BigInteger; import java.math.BigInteger;

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir; package meerkat.crypto.secretsharing.shamir;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import java.math.BigInteger; import java.math.BigInteger;
import java.util.Arrays; import java.util.Arrays;
@ -100,7 +100,7 @@ public class Polynomial implements Comparable<Polynomial> {
/** /**
* @param other * @param other
* @return new meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial of degree max(this degree,other degree) s.t for all x * @return new Polynomial of degree max(this degree,other degree) s.t for all x
* new.evaluate(x) = this.evaluate(x) + other.evaluate(x) * new.evaluate(x) = this.evaluate(x) + other.evaluate(x)
*/ */
public Polynomial add(Polynomial other){ public Polynomial add(Polynomial other){

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir; package meerkat.crypto.secretsharing.shamir;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.concrete.Fp;
import java.math.BigInteger; import java.math.BigInteger;
import java.util.Random; import java.util.Random;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
/** /**
* Created by Tzlil on 3/17/2016. * Created by Tzlil on 3/17/2016.

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.utilitis.concrete; package meerkat.crypto.utils.concrete;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import org.factcenter.qilin.primitives.concrete.Zpstar; import org.factcenter.qilin.primitives.concrete.Zpstar;
import java.math.BigInteger; import java.math.BigInteger;

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import java.math.BigInteger; import java.math.BigInteger;
import java.util.*; import java.util.*;
@ -44,7 +44,7 @@ public class DKGMaliciousUser<T> extends User<T> {
@Override @Override
public void stage1() { public void stage1() {
dkg.broadcastCommitments(); dkg.broadcastCommitments();
sendSecrets(); //insteadof dkg.sendSecrets(channel); sendSecrets(); //insteadof crypto.sendSecrets(channel);
} }
@Override @Override

View File

@ -1,18 +1,17 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import meerkat.destributed_key_generation.utilitis.ChannelImpl; import meerkat.crypto.utils.ChannelImpl;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.concrete.Fp;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.destributed_key_generation.concrete.secret_shring.feldman_verifiable.VerifiableSecretSharing; import meerkat.crypto.secretsharing.feldman.VerifiableSecretSharing;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.SecretSharing; import meerkat.crypto.secretsharing.shamir.SecretSharing;
import meerkat.destributed_key_generation.utilitis.BigIntegerByteEncoder; import meerkat.crypto.utils.BigIntegerByteEncoder;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPrime; import meerkat.crypto.utils.GenerateRandomPrime;
import org.factcenter.qilin.primitives.Group; import org.factcenter.qilin.primitives.Group;
import org.factcenter.qilin.primitives.concrete.Zpstar; import org.factcenter.qilin.primitives.concrete.Zpstar;
import org.factcenter.qilin.util.ByteEncoder; import org.factcenter.qilin.util.ByteEncoder;
import org.junit.Before;
import org.junit.Test; import org.junit.Test;
import java.math.BigInteger; import java.math.BigInteger;
@ -122,7 +121,7 @@ public class DKGTest {
id = ids.remove(random.nextInt(ids.size())); id = ids.remove(random.nextInt(ids.size()));
channel = new ChannelImpl(id,n); channel = new ChannelImpl(id,n);
s = randomIntModQ(random); s = randomIntModQ(random);
dkg = new meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.Protocol<BigInteger>(t, n, s, random, q, g, group, id,byteEncoder); dkg = new meerkat.crypto.dkg.feldman.Protocol<BigInteger>(t, n, s, random, q, g, group, id,byteEncoder);
dkgs[id - 1] = randomDKGUser(id,channel,dkg,random); dkgs[id - 1] = randomDKGUser(id,channel,dkg,random);
threads[id - 1] = new Thread(dkgs[id - 1]); threads[id - 1] = new Thread(dkgs[id - 1]);
if(QUAL.contains(id)){ if(QUAL.contains(id)){

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol; package meerkat.crypto.dkg.feldman;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
/** /**

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import java.math.BigInteger; import java.math.BigInteger;
import java.util.Random; import java.util.Random;
@ -33,7 +33,7 @@ public class SDKGMaliciousUserImpl<T> extends User<T> {
@Override @Override
public void stage1() { public void stage1() {
sdkg.computeAndBroadcastVerificationValues(); sdkg.computeAndBroadcastVerificationValues();
sendSecrets(); //insteadof dkg.sendSecrets(channel); sendSecrets(); //insteadof crypto.sendSecrets(channel);
} }
@Override @Override

View File

@ -1,19 +1,18 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import meerkat.destributed_key_generation.utilitis.ChannelImpl; import meerkat.crypto.utils.ChannelImpl;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.utils.Arithmetic;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.concrete.Fp;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.destributed_key_generation.concrete.secret_shring.feldman_verifiable.VerifiableSecretSharing; import meerkat.crypto.secretsharing.feldman.VerifiableSecretSharing;
import meerkat.destributed_key_generation.concrete.distributed_key_generation.joint_feldman_protocol.DKGMaliciousUser; import meerkat.crypto.dkg.feldman.DKGMaliciousUser;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.SecretSharing; import meerkat.crypto.secretsharing.shamir.SecretSharing;
import meerkat.destributed_key_generation.utilitis.BigIntegerByteEncoder; import meerkat.crypto.utils.BigIntegerByteEncoder;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPrime; import meerkat.crypto.utils.GenerateRandomPrime;
import org.factcenter.qilin.primitives.Group; import org.factcenter.qilin.primitives.Group;
import org.factcenter.qilin.primitives.concrete.Zpstar; import org.factcenter.qilin.primitives.concrete.Zpstar;
import org.factcenter.qilin.util.ByteEncoder; import org.factcenter.qilin.util.ByteEncoder;
import org.junit.Before;
import org.junit.Test; import org.junit.Test;
import java.math.BigInteger; import java.math.BigInteger;

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.distributed_key_generation.gjkr_secure_protocol; package meerkat.crypto.dkg.gjkr;
import meerkat.destributed_key_generation.utilitis.Channel; import meerkat.crypto.utils.Channel;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;
/** /**

View File

@ -1,6 +1,6 @@
package meerkat.destributed_key_generation.concrete.secret_shring.feldman_verifiable; package meerkat.crypto.secretsharing.feldman;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import org.factcenter.qilin.primitives.Group; import org.factcenter.qilin.primitives.Group;
import org.factcenter.qilin.primitives.concrete.Zpstar; import org.factcenter.qilin.primitives.concrete.Zpstar;
import org.junit.Before; import org.junit.Before;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir.PolynomialTests; package meerkat.crypto.secretsharing.shamir.PolynomialTests;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPolynomial; import meerkat.crypto.utils.GenerateRandomPolynomial;
import meerkat.destributed_key_generation.utilitis.Z; import meerkat.crypto.utils.Z;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import org.junit.Before; import org.junit.Before;
import org.junit.Test; import org.junit.Test;

View File

@ -1,10 +1,10 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir.PolynomialTests; package meerkat.crypto.secretsharing.shamir.PolynomialTests;
import meerkat.destributed_key_generation.utilitis.Arithmetic; import meerkat.crypto.secretsharing.shamir.Polynomial;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.Arithmetic;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPolynomial; import meerkat.crypto.utils.concrete.Fp;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.utils.GenerateRandomPolynomial;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPrime; import meerkat.crypto.utils.GenerateRandomPrime;
import org.junit.Before; import org.junit.Before;
import org.junit.Test; import org.junit.Test;

View File

@ -1,8 +1,8 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir.PolynomialTests; package meerkat.crypto.secretsharing.shamir.PolynomialTests;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPolynomial; import meerkat.crypto.utils.GenerateRandomPolynomial;
import meerkat.destributed_key_generation.utilitis.Z; import meerkat.crypto.utils.Z;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import org.junit.Before; import org.junit.Before;
import org.junit.Test; import org.junit.Test;

View File

@ -1,8 +1,8 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir.PolynomialTests; package meerkat.crypto.secretsharing.shamir.PolynomialTests;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPolynomial; import meerkat.crypto.utils.GenerateRandomPolynomial;
import meerkat.destributed_key_generation.utilitis.Z; import meerkat.crypto.utils.Z;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import org.junit.Before; import org.junit.Before;
import org.junit.Test; import org.junit.Test;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.concrete.secret_shring.shamir; package meerkat.crypto.secretsharing.shamir;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.concrete.Fp;
import meerkat.destributed_key_generation.utilitis.GenerateRandomPrime; import meerkat.crypto.utils.GenerateRandomPrime;
import org.factcenter.qilin.primitives.CyclicGroup; import org.factcenter.qilin.primitives.CyclicGroup;
import org.factcenter.qilin.primitives.concrete.Zn; import org.factcenter.qilin.primitives.concrete.Zn;
import org.junit.Before; import org.junit.Before;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
import java.math.BigInteger; import java.math.BigInteger;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.protobuf.DKGMessages; import meerkat.protobuf.DKGMessages;

View File

@ -1,7 +1,7 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
import meerkat.destributed_key_generation.concrete.secret_shring.shamir.Polynomial; import meerkat.crypto.secretsharing.shamir.Polynomial;
import meerkat.destributed_key_generation.utilitis.concrete.Fp; import meerkat.crypto.utils.concrete.Fp;
import java.math.BigInteger; import java.math.BigInteger;
import java.util.Random; import java.util.Random;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
import java.math.BigInteger; import java.math.BigInteger;
import java.util.Random; import java.util.Random;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.utilitis; package meerkat.crypto.utils;
import java.math.BigInteger; import java.math.BigInteger;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation; package meerkat.crypto;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation; package meerkat.crypto;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation; package meerkat.crypto;
import com.google.protobuf.InvalidProtocolBufferException; import com.google.protobuf.InvalidProtocolBufferException;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
@ -16,7 +16,7 @@ import org.slf4j.LoggerFactory;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.destributed_key_generation.DigitalSignature; import meerkat.crypto.DigitalSignature;
import meerkat.protobuf.Crypto.Signature; import meerkat.protobuf.Crypto.Signature;
import javax.security.auth.callback.Callback; import javax.security.auth.callback.Callback;

View File

@ -1,9 +1,9 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.InvalidProtocolBufferException; import com.google.protobuf.InvalidProtocolBufferException;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.destributed_key_generation.Encryption; import meerkat.crypto.Encryption;
import meerkat.protobuf.ConcreteCrypto; import meerkat.protobuf.ConcreteCrypto;
import meerkat.protobuf.Crypto; import meerkat.protobuf.Crypto;
import org.bouncycastle.crypto.params.AsymmetricKeyParameter; import org.bouncycastle.crypto.params.AsymmetricKeyParameter;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import org.bouncycastle.jce.provider.BouncyCastleProvider; import org.bouncycastle.jce.provider.BouncyCastleProvider;
import org.slf4j.Logger; import org.slf4j.Logger;
@ -8,7 +8,7 @@ import java.security.Provider;
import java.security.Security; import java.security.Security;
/** /**
* A class that performs required destributed_key_generation setup * A class that performs required crypto setup
*/ */
public class GlobalCryptoSetup { public class GlobalCryptoSetup {
final static Logger logger = LoggerFactory.getLogger(GlobalCryptoSetup.class); final static Logger logger = LoggerFactory.getLogger(GlobalCryptoSetup.class);

View File

@ -1,8 +1,8 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.Message; import com.google.protobuf.Message;
import meerkat.destributed_key_generation.Digest; import meerkat.crypto.Digest;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.mixnet; package meerkat.crypto.mixnet;
import meerkat.protobuf.Crypto; import meerkat.protobuf.Crypto;
import meerkat.protobuf.Mixing; import meerkat.protobuf.Mixing;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.mixnet; package meerkat.crypto.mixnet;
import meerkat.protobuf.Crypto; import meerkat.protobuf.Crypto;
import meerkat.protobuf.Mixing; import meerkat.protobuf.Mixing;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.mixnet; package meerkat.crypto.mixnet;
import java.util.List; import java.util.List;
import static meerkat.protobuf.Voting.*; import static meerkat.protobuf.Voting.*;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.mixnet; package meerkat.crypto.mixnet;
/** /**
* Created by talm on 25/10/15. * Created by talm on 25/10/15.

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.mixnet; package meerkat.crypto.mixnet;
/** /**
* Created by talm on 25/10/15. * Created by talm on 25/10/15.

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.Message; import com.google.protobuf.Message;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import meerkat.protobuf.ConcreteCrypto; import meerkat.protobuf.ConcreteCrypto;
import meerkat.protobuf.Crypto; import meerkat.protobuf.Crypto;

View File

@ -1,4 +1,4 @@
package meerkat.destributed_key_generation.concrete; package meerkat.crypto.concrete;
import com.google.protobuf.ByteString; import com.google.protobuf.ByteString;
import com.google.protobuf.GeneratedMessage; import com.google.protobuf.GeneratedMessage;

View File

@ -4,5 +4,5 @@ include 'bulletin-board-server'
include 'polling-station' include 'polling-station'
include 'restful-api-common' include 'restful-api-common'
include 'bulletin-board-client' include 'bulletin-board-client'
include 'destributed-key-generation' include 'distributed-key-generation'