public class TlsDHKeyExchange extends AbstractTlsKeyExchange
Modifier and Type | Field and Description |
---|---|
protected TlsAgreementCredentials |
agreementCredentials |
protected DHPrivateKeyParameters |
dhAgreeClientPrivateKey |
protected DHPublicKeyParameters |
dhAgreeClientPublicKey |
protected DHPrivateKeyParameters |
dhAgreeServerPrivateKey |
protected DHPublicKeyParameters |
dhAgreeServerPublicKey |
protected DHParameters |
dhParameters |
protected static java.math.BigInteger |
ONE |
protected AsymmetricKeyParameter |
serverPublicKey |
protected TlsSigner |
tlsSigner |
protected static java.math.BigInteger |
TWO |
context, keyExchange, supportedSignatureAlgorithms
Constructor and Description |
---|
TlsDHKeyExchange(int keyExchange,
java.util.Vector supportedSignatureAlgorithms,
DHParameters dhParameters) |
Modifier and Type | Method and Description |
---|---|
void |
generateClientKeyExchange(java.io.OutputStream output) |
byte[] |
generatePremasterSecret() |
void |
init(TlsContext context) |
void |
processClientCredentials(TlsCredentials clientCredentials) |
void |
processServerCertificate(Certificate serverCertificate) |
boolean |
requiresServerKeyExchange() |
void |
skipServerCredentials() |
void |
validateCertificateRequest(CertificateRequest certificateRequest) |
generateServerKeyExchange, processClientCertificate, processClientKeyExchange, processServerCredentials, processServerKeyExchange, skipClientCredentials, skipServerKeyExchange
protected static final java.math.BigInteger ONE
protected static final java.math.BigInteger TWO
protected TlsSigner tlsSigner
protected DHParameters dhParameters
protected AsymmetricKeyParameter serverPublicKey
protected DHPublicKeyParameters dhAgreeServerPublicKey
protected TlsAgreementCredentials agreementCredentials
protected DHPrivateKeyParameters dhAgreeClientPrivateKey
protected DHPrivateKeyParameters dhAgreeServerPrivateKey
protected DHPublicKeyParameters dhAgreeClientPublicKey
public TlsDHKeyExchange(int keyExchange, java.util.Vector supportedSignatureAlgorithms, DHParameters dhParameters)
public void init(TlsContext context)
init
in interface TlsKeyExchange
init
in class AbstractTlsKeyExchange
public void skipServerCredentials() throws java.io.IOException
java.io.IOException
public void processServerCertificate(Certificate serverCertificate) throws java.io.IOException
processServerCertificate
in interface TlsKeyExchange
processServerCertificate
in class AbstractTlsKeyExchange
java.io.IOException
public boolean requiresServerKeyExchange()
requiresServerKeyExchange
in interface TlsKeyExchange
requiresServerKeyExchange
in class AbstractTlsKeyExchange
public void validateCertificateRequest(CertificateRequest certificateRequest) throws java.io.IOException
java.io.IOException
public void processClientCredentials(TlsCredentials clientCredentials) throws java.io.IOException
java.io.IOException
public void generateClientKeyExchange(java.io.OutputStream output) throws java.io.IOException
java.io.IOException
public byte[] generatePremasterSecret() throws java.io.IOException
java.io.IOException