Package org.bouncycastle.crypto.tls
Class AbstractTlsServer
- java.lang.Object
-
- org.bouncycastle.crypto.tls.AbstractTlsPeer
-
- org.bouncycastle.crypto.tls.AbstractTlsServer
-
- Direct Known Subclasses:
DefaultTlsServer,PSKTlsServer,SRPTlsServer
public abstract class AbstractTlsServer extends AbstractTlsPeer implements TlsServer
Deprecated.Migrate to the (D)TLS API in org.bouncycastle.tls (bctls jar).
-
-
Field Summary
Fields Modifier and Type Field Description protected TlsCipherFactorycipherFactoryDeprecated.protected short[]clientECPointFormatsDeprecated.protected java.util.HashtableclientExtensionsDeprecated.protected ProtocolVersionclientVersionDeprecated.protected TlsServerContextcontextDeprecated.protected booleaneccCipherSuitesOfferedDeprecated.protected booleanencryptThenMACOfferedDeprecated.protected shortmaxFragmentLengthOfferedDeprecated.protected int[]namedCurvesDeprecated.protected int[]offeredCipherSuitesDeprecated.protected short[]offeredCompressionMethodsDeprecated.protected intselectedCipherSuiteDeprecated.protected shortselectedCompressionMethodDeprecated.protected short[]serverECPointFormatsDeprecated.protected java.util.HashtableserverExtensionsDeprecated.protected ProtocolVersionserverVersionDeprecated.protected java.util.VectorsupportedSignatureAlgorithmsDeprecated.protected booleantruncatedHMacOfferedDeprecated.
-
Constructor Summary
Constructors Constructor Description AbstractTlsServer()Deprecated.AbstractTlsServer(TlsCipherFactory cipherFactory)Deprecated.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected booleanallowEncryptThenMAC()Deprecated.protected booleanallowTruncatedHMac()Deprecated.protected java.util.HashtablecheckServerExtensions()Deprecated.CertificateRequestgetCertificateRequest()Deprecated.CertificateStatusgetCertificateStatus()Deprecated.This method will be called (only) if the server included an extension of type "status_request" with empty "extension_data" in the extended server hello.TlsCiphergetCipher()Deprecated.protected abstract int[]getCipherSuites()Deprecated.TlsCompressiongetCompression()Deprecated.protected short[]getCompressionMethods()Deprecated.protected ProtocolVersiongetMaximumVersion()Deprecated.protected ProtocolVersiongetMinimumVersion()Deprecated.NewSessionTicketgetNewSessionTicket()Deprecated.RFC 5077 3.3.intgetSelectedCipherSuite()Deprecated.shortgetSelectedCompressionMethod()Deprecated.java.util.HashtablegetServerExtensions()Deprecated.java.util.VectorgetServerSupplementalData()Deprecated.ProtocolVersiongetServerVersion()Deprecated.voidinit(TlsServerContext context)Deprecated.voidnotifyClientCertificate(Certificate clientCertificate)Deprecated.Called by the protocol handler to report the client certificate, only ifTlsServer.getCertificateRequest()returned non-null.voidnotifyClientVersion(ProtocolVersion clientVersion)Deprecated.voidnotifyFallback(boolean isFallback)Deprecated.voidnotifyOfferedCipherSuites(int[] offeredCipherSuites)Deprecated.voidnotifyOfferedCompressionMethods(short[] offeredCompressionMethods)Deprecated.voidprocessClientExtensions(java.util.Hashtable clientExtensions)Deprecated.voidprocessClientSupplementalData(java.util.Vector clientSupplementalData)Deprecated.protected booleansupportsClientECCCapabilities(int[] namedCurves, short[] ecPointFormats)Deprecated.-
Methods inherited from class org.bouncycastle.crypto.tls.AbstractTlsPeer
cancel, notifyAlertRaised, notifyAlertReceived, notifyCloseHandle, notifyHandshakeComplete, notifySecureRenegotiation, requiresExtendedMasterSecret, shouldUseGMTUnixTime
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.bouncycastle.crypto.tls.TlsPeer
cancel, notifyAlertRaised, notifyAlertReceived, notifyCloseHandle, notifyHandshakeComplete, notifySecureRenegotiation, requiresExtendedMasterSecret, shouldUseGMTUnixTime
-
Methods inherited from interface org.bouncycastle.crypto.tls.TlsServer
getCredentials, getKeyExchange
-
-
-
-
Field Detail
-
cipherFactory
protected TlsCipherFactory cipherFactory
Deprecated.
-
context
protected TlsServerContext context
Deprecated.
-
clientVersion
protected ProtocolVersion clientVersion
Deprecated.
-
offeredCipherSuites
protected int[] offeredCipherSuites
Deprecated.
-
offeredCompressionMethods
protected short[] offeredCompressionMethods
Deprecated.
-
clientExtensions
protected java.util.Hashtable clientExtensions
Deprecated.
-
encryptThenMACOffered
protected boolean encryptThenMACOffered
Deprecated.
-
maxFragmentLengthOffered
protected short maxFragmentLengthOffered
Deprecated.
-
truncatedHMacOffered
protected boolean truncatedHMacOffered
Deprecated.
-
supportedSignatureAlgorithms
protected java.util.Vector supportedSignatureAlgorithms
Deprecated.
-
eccCipherSuitesOffered
protected boolean eccCipherSuitesOffered
Deprecated.
-
namedCurves
protected int[] namedCurves
Deprecated.
-
clientECPointFormats
protected short[] clientECPointFormats
Deprecated.
-
serverECPointFormats
protected short[] serverECPointFormats
Deprecated.
-
serverVersion
protected ProtocolVersion serverVersion
Deprecated.
-
selectedCipherSuite
protected int selectedCipherSuite
Deprecated.
-
selectedCompressionMethod
protected short selectedCompressionMethod
Deprecated.
-
serverExtensions
protected java.util.Hashtable serverExtensions
Deprecated.
-
-
Constructor Detail
-
AbstractTlsServer
public AbstractTlsServer()
Deprecated.
-
AbstractTlsServer
public AbstractTlsServer(TlsCipherFactory cipherFactory)
Deprecated.
-
-
Method Detail
-
allowEncryptThenMAC
protected boolean allowEncryptThenMAC()
Deprecated.
-
allowTruncatedHMac
protected boolean allowTruncatedHMac()
Deprecated.
-
checkServerExtensions
protected java.util.Hashtable checkServerExtensions()
Deprecated.
-
getCipherSuites
protected abstract int[] getCipherSuites()
Deprecated.
-
getCompressionMethods
protected short[] getCompressionMethods()
Deprecated.
-
getMaximumVersion
protected ProtocolVersion getMaximumVersion()
Deprecated.
-
getMinimumVersion
protected ProtocolVersion getMinimumVersion()
Deprecated.
-
supportsClientECCCapabilities
protected boolean supportsClientECCCapabilities(int[] namedCurves, short[] ecPointFormats)Deprecated.
-
init
public void init(TlsServerContext context)
Deprecated.
-
notifyClientVersion
public void notifyClientVersion(ProtocolVersion clientVersion) throws java.io.IOException
Deprecated.- Specified by:
notifyClientVersionin interfaceTlsServer- Throws:
java.io.IOException
-
notifyFallback
public void notifyFallback(boolean isFallback) throws java.io.IOExceptionDeprecated.- Specified by:
notifyFallbackin interfaceTlsServer- Throws:
java.io.IOException
-
notifyOfferedCipherSuites
public void notifyOfferedCipherSuites(int[] offeredCipherSuites) throws java.io.IOExceptionDeprecated.- Specified by:
notifyOfferedCipherSuitesin interfaceTlsServer- Throws:
java.io.IOException
-
notifyOfferedCompressionMethods
public void notifyOfferedCompressionMethods(short[] offeredCompressionMethods) throws java.io.IOExceptionDeprecated.- Specified by:
notifyOfferedCompressionMethodsin interfaceTlsServer- Throws:
java.io.IOException
-
processClientExtensions
public void processClientExtensions(java.util.Hashtable clientExtensions) throws java.io.IOExceptionDeprecated.- Specified by:
processClientExtensionsin interfaceTlsServer- Throws:
java.io.IOException
-
getServerVersion
public ProtocolVersion getServerVersion() throws java.io.IOException
Deprecated.- Specified by:
getServerVersionin interfaceTlsServer- Throws:
java.io.IOException
-
getSelectedCipherSuite
public int getSelectedCipherSuite() throws java.io.IOExceptionDeprecated.- Specified by:
getSelectedCipherSuitein interfaceTlsServer- Throws:
java.io.IOException
-
getSelectedCompressionMethod
public short getSelectedCompressionMethod() throws java.io.IOExceptionDeprecated.- Specified by:
getSelectedCompressionMethodin interfaceTlsServer- Throws:
java.io.IOException
-
getServerExtensions
public java.util.Hashtable getServerExtensions() throws java.io.IOExceptionDeprecated.- Specified by:
getServerExtensionsin interfaceTlsServer- Throws:
java.io.IOException
-
getServerSupplementalData
public java.util.Vector getServerSupplementalData() throws java.io.IOExceptionDeprecated.- Specified by:
getServerSupplementalDatain interfaceTlsServer- Throws:
java.io.IOException
-
getCertificateStatus
public CertificateStatus getCertificateStatus() throws java.io.IOException
Deprecated.Description copied from interface:TlsServerThis method will be called (only) if the server included an extension of type "status_request" with empty "extension_data" in the extended server hello. See RFC 3546 3.6. Certificate Status Request. If a non-nullCertificateStatusis returned, it is sent to the client as a handshake message of type "certificate_status".- Specified by:
getCertificateStatusin interfaceTlsServer- Returns:
- A
CertificateStatusto be sent to the client (or null for none). - Throws:
java.io.IOException
-
getCertificateRequest
public CertificateRequest getCertificateRequest() throws java.io.IOException
Deprecated.- Specified by:
getCertificateRequestin interfaceTlsServer- Throws:
java.io.IOException
-
processClientSupplementalData
public void processClientSupplementalData(java.util.Vector clientSupplementalData) throws java.io.IOExceptionDeprecated.- Specified by:
processClientSupplementalDatain interfaceTlsServer- Throws:
java.io.IOException
-
notifyClientCertificate
public void notifyClientCertificate(Certificate clientCertificate) throws java.io.IOException
Deprecated.Description copied from interface:TlsServerCalled by the protocol handler to report the client certificate, only ifTlsServer.getCertificateRequest()returned non-null. Note: this method is responsible for certificate verification and validation.- Specified by:
notifyClientCertificatein interfaceTlsServer- Parameters:
clientCertificate- the effective client certificate (may be an empty chain).- Throws:
java.io.IOException
-
getCompression
public TlsCompression getCompression() throws java.io.IOException
Deprecated.- Specified by:
getCompressionin interfaceTlsPeer- Throws:
java.io.IOException
-
getCipher
public TlsCipher getCipher() throws java.io.IOException
Deprecated.
-
getNewSessionTicket
public NewSessionTicket getNewSessionTicket() throws java.io.IOException
Deprecated.Description copied from interface:TlsServerRFC 5077 3.3. NewSessionTicket Handshake Message.This method will be called (only) if a NewSessionTicket extension was sent by the server. See RFC 5077 4. Recommended Ticket Construction for recommended format and protection.
- Specified by:
getNewSessionTicketin interfaceTlsServer- Returns:
- The ticket.
- Throws:
java.io.IOException
-
-