org.bouncycastle.crypto.tls
Class TlsECDHKeyExchange
java.lang.Object
org.bouncycastle.crypto.tls.AbstractTlsKeyExchange
org.bouncycastle.crypto.tls.TlsECDHKeyExchange
- All Implemented Interfaces:
- TlsKeyExchange
- Direct Known Subclasses:
- TlsECDHEKeyExchange
public class TlsECDHKeyExchange
- extends AbstractTlsKeyExchange
ECDH key exchange (see RFC 4492)
Constructor Summary |
TlsECDHKeyExchange(int keyExchange,
java.util.Vector supportedSignatureAlgorithms,
int[] namedCurves,
short[] clientECPointFormats,
short[] serverECPointFormats)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
tlsSigner
protected TlsSigner tlsSigner
namedCurves
protected int[] namedCurves
clientECPointFormats
protected short[] clientECPointFormats
serverECPointFormats
protected short[] serverECPointFormats
serverPublicKey
protected AsymmetricKeyParameter serverPublicKey
agreementCredentials
protected TlsAgreementCredentials agreementCredentials
ecAgreePrivateKey
protected ECPrivateKeyParameters ecAgreePrivateKey
ecAgreePublicKey
protected ECPublicKeyParameters ecAgreePublicKey
TlsECDHKeyExchange
public TlsECDHKeyExchange(int keyExchange,
java.util.Vector supportedSignatureAlgorithms,
int[] namedCurves,
short[] clientECPointFormats,
short[] serverECPointFormats)
init
public void init(TlsContext context)
- Specified by:
init
in interface TlsKeyExchange
- Overrides:
init
in class AbstractTlsKeyExchange
skipServerCredentials
public void skipServerCredentials()
throws java.io.IOException
- Throws:
java.io.IOException
processServerCertificate
public void processServerCertificate(Certificate serverCertificate)
throws java.io.IOException
- Specified by:
processServerCertificate
in interface TlsKeyExchange
- Overrides:
processServerCertificate
in class AbstractTlsKeyExchange
- Throws:
java.io.IOException
requiresServerKeyExchange
public boolean requiresServerKeyExchange()
- Specified by:
requiresServerKeyExchange
in interface TlsKeyExchange
- Overrides:
requiresServerKeyExchange
in class AbstractTlsKeyExchange
validateCertificateRequest
public void validateCertificateRequest(CertificateRequest certificateRequest)
throws java.io.IOException
- Throws:
java.io.IOException
processClientCredentials
public void processClientCredentials(TlsCredentials clientCredentials)
throws java.io.IOException
- Throws:
java.io.IOException
generateClientKeyExchange
public void generateClientKeyExchange(java.io.OutputStream output)
throws java.io.IOException
- Throws:
java.io.IOException
processClientCertificate
public void processClientCertificate(Certificate clientCertificate)
throws java.io.IOException
- Specified by:
processClientCertificate
in interface TlsKeyExchange
- Overrides:
processClientCertificate
in class AbstractTlsKeyExchange
- Throws:
java.io.IOException
processClientKeyExchange
public void processClientKeyExchange(java.io.InputStream input)
throws java.io.IOException
- Specified by:
processClientKeyExchange
in interface TlsKeyExchange
- Overrides:
processClientKeyExchange
in class AbstractTlsKeyExchange
- Throws:
java.io.IOException
generatePremasterSecret
public byte[] generatePremasterSecret()
throws java.io.IOException
- Throws:
java.io.IOException