PSKTlsServer (Bouncy Castle Library 1.52 API Specification)
Date: 2015-03-01

org.bouncycastle.crypto.tls

## Class PSKTlsServer

- java.lang.Object
- - org.bouncycastle.crypto.tls.AbstractTlsPeer
  - - org.bouncycastle.crypto.tls.AbstractTlsServer
    - - org.bouncycastle.crypto.tls.PSKTlsServer

- All Implemented Interfaces:
    TlsPeer, TlsServer

      public class PSKTlsServer
      extends AbstractTlsServer

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected TlsPSKIdentityManager` | `pskIdentityManager`

    - ### Fields inherited from class org.bouncycastle.crypto.tls.AbstractTlsServer

      `cipherFactory, clientECPointFormats, clientExtensions, clientVersion, context, eccCipherSuitesOffered, encryptThenMACOffered, maxFragmentLengthOffered, namedCurves, offeredCipherSuites, offeredCompressionMethods, selectedCipherSuite, selectedCompressionMethod, serverECPointFormats, serverExtensions, serverVersion, supportedSignatureAlgorithms, truncatedHMacOffered`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `PSKTlsServer(TlsCipherFactory cipherFactory, TlsPSKIdentityManager pskIdentityManager)`
    `PSKTlsServer(TlsPSKIdentityManager pskIdentityManager)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected TlsKeyExchange` | `createPSKKeyExchange(int keyExchange)`
    `TlsCipher` | `getCipher()`
    `protected int[]` | `getCipherSuites()`
    `TlsCredentials` | `getCredentials()`
    `protected DHParameters` | `getDHParameters()`
    `TlsKeyExchange` | `getKeyExchange()`
    `protected TlsEncryptionCredentials` | `getRSAEncryptionCredentials()`

    - ### Methods inherited from class org.bouncycastle.crypto.tls.AbstractTlsServer

      `allowEncryptThenMAC, allowTruncatedHMac, checkServerExtensions, getCertificateRequest, getCertificateStatus, getCompression, getCompressionMethods, getMaximumVersion, getMinimumVersion, getNewSessionTicket, getSelectedCipherSuite, getSelectedCompressionMethod, getServerExtensions, getServerSupplementalData, getServerVersion, init, notifyClientCertificate, notifyClientVersion, notifyFallback, notifyOfferedCipherSuites, notifyOfferedCompressionMethods, processClientExtensions, processClientSupplementalData, supportsClientECCCapabilities`

    - ### Methods inherited from class org.bouncycastle.crypto.tls.AbstractTlsPeer

      `notifyAlertRaised, notifyAlertReceived, notifyHandshakeComplete, notifySecureRenegotiation, 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

      `notifyAlertRaised, notifyAlertReceived, notifyHandshakeComplete, notifySecureRenegotiation, shouldUseGMTUnixTime`

- - ### Field Detail

    - #### pskIdentityManager

          protected TlsPSKIdentityManager pskIdentityManager

  - ### Constructor Detail

    - #### PSKTlsServer

          public PSKTlsServer(TlsPSKIdentityManager pskIdentityManager)

    - #### PSKTlsServer

          public PSKTlsServer(TlsCipherFactory cipherFactory,
                      TlsPSKIdentityManager pskIdentityManager)

  - ### Method Detail

    - #### getRSAEncryptionCredentials

          protected TlsEncryptionCredentials getRSAEncryptionCredentials()
                                                                  throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### getDHParameters

          protected DHParameters getDHParameters()

    - #### getCipherSuites

          protected int[] getCipherSuites()

      Specified by:
        `getCipherSuites` in class `AbstractTlsServer`

    - #### getCredentials

          public TlsCredentials getCredentials()
                                        throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### getKeyExchange

          public TlsKeyExchange getKeyExchange()
                                        throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### getCipher

          public TlsCipher getCipher()
                              throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### createPSKKeyExchange

          protected TlsKeyExchange createPSKKeyExchange(int keyExchange)