public class DefaultTlsDHGroupVerifier extends java.lang.Object implements TlsDHGroupVerifier
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_MINIMUM_PRIME_BITS |
protected java.util.Vector |
groups |
protected int |
minimumPrimeBits |
| Constructor and Description |
|---|
DefaultTlsDHGroupVerifier()
Accept named groups and various standard DH groups with 'P' at least
DEFAULT_MINIMUM_PRIME_BITS bits. |
DefaultTlsDHGroupVerifier(int minimumPrimeBits)
Accept named groups and various standard DH groups with 'P' at least the specified number of bits.
|
DefaultTlsDHGroupVerifier(java.util.Vector groups,
int minimumPrimeBits)
Accept named groups and a custom set of group parameters, subject to a minimum bitlength for 'P'.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
accept(DHGroup dhGroup)
Check whether the given DH group is acceptable for use.
|
protected boolean |
areGroupsEqual(DHGroup a,
DHGroup b) |
protected boolean |
areParametersEqual(java.math.BigInteger a,
java.math.BigInteger b) |
protected boolean |
checkGroup(DHGroup dhGroup) |
protected boolean |
checkMinimumPrimeBits(DHGroup dhGroup) |
int |
getMinimumPrimeBits() |
public static final int DEFAULT_MINIMUM_PRIME_BITS
protected java.util.Vector groups
protected int minimumPrimeBits
public DefaultTlsDHGroupVerifier()
DEFAULT_MINIMUM_PRIME_BITS bits.public DefaultTlsDHGroupVerifier(int minimumPrimeBits)
public DefaultTlsDHGroupVerifier(java.util.Vector groups,
int minimumPrimeBits)
groups - a Vector of acceptable DHGroups.public boolean accept(DHGroup dhGroup)
TlsDHGroupVerifieraccept in interface TlsDHGroupVerifierdhGroup - the DHGroup to checkpublic int getMinimumPrimeBits()
protected boolean areParametersEqual(java.math.BigInteger a,
java.math.BigInteger b)
protected boolean checkGroup(DHGroup dhGroup)
protected boolean checkMinimumPrimeBits(DHGroup dhGroup)