|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectvotingSystem.KeyGenerator
This class will be used to generate the keys for the decryption servers, as well as the public key for the election.
Constructor Summary | |
KeyGenerator(java.util.Random r,
int bitlength,
int s)
This constructor will make a new KeyGenerator with the Random-generator r |
Method Summary | |
KeyShare[] |
generateKeys(int l,
int w)
Generates the KeyShares for the decryption servers |
java.math.BigInteger[] |
generateSafePrime(int bitlength)
Generates a safe prime (p = 2p' + 1) where p' is a prime with 1-2^100 probability |
java.math.BigInteger |
getD()
|
java.math.BigInteger |
getG()
|
java.math.BigInteger |
getM()
|
java.math.BigInteger |
getN()
|
java.math.BigInteger |
getP()
|
PublicKey |
getPk()
|
java.math.BigInteger |
getQ()
|
java.util.Random |
getR()
|
int |
getS()
|
java.math.BigInteger |
getV()
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public KeyGenerator(java.util.Random r, int bitlength, int s)
r
- A Random generatorbitlength
- The bitlength of the keys
- The exponent used in the cryptosystem.Method Detail |
public KeyShare[] generateKeys(int l, int w)
l
- Number of decryption serversw
- Number of decryption servers needed to perform decryption
public java.math.BigInteger[] generateSafePrime(int bitlength)
bitlength
- The bitlength of the primes to be generated
public java.math.BigInteger getD()
public java.math.BigInteger getM()
public java.math.BigInteger getN()
public java.util.Random getR()
public int getS()
public java.math.BigInteger getV()
public java.math.BigInteger getG()
public java.math.BigInteger getP()
public java.math.BigInteger getQ()
public PublicKey getPk()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |