Package tigase.io

# Class JcaTLSWrapper

java.lang.Object
tigase.io.JcaTLSWrapper

All Implemented Interfaces:
  `TLSWrapper`

public class JcaTLSWrapper extends Object implements TLSWrapper
Describe class TLSWrapper here.
Created: Sat Mar 5 09:13:29 2005

Author:
  Artur Hefczyc

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `JcaTLSWrapper(SSLContext sslc, TLSEventHandler eventHandler, String hostname, int port, boolean clientMode, boolean wantClientAuth)`
  `JcaTLSWrapper(SSLContext sslc, TLSEventHandler eventHandler, String hostname, int port, boolean clientMode, boolean wantClientAuth, boolean needClientAuth)`
  Creates a new `TLSWrapper` instance.
  `JcaTLSWrapper(SSLContext sslc, TLSEventHandler eventHandler, String remote_hostname, int port, boolean clientMode, boolean wantClientAuth, boolean needClientAuth, String[] enabledCiphers, String[] enabledProtocols)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `bytesConsumed()`
  `void`
  `close()`
  `int`
  `getAppBuffSize()`
  `CertCheckResult`
  `getCertificateStatus(boolean revocationEnabled, SSLContextContainerIfc sslContextContainer)`
  `SSLEngineResult.HandshakeStatus`
  `getHandshakeStatus()`
  `Certificate[]`
  `getLocalCertificates()`
  `int`
  `getNetBuffSize()`
  `int`
  `getPacketBuffSize()`
  `Certificate[]`
  `getPeerCertificates()`
  `TLSStatus`
  `getStatus()`
  `byte[]`
  `getTlsUniqueBindingData()`
  `boolean`
  `isClientMode()`
  `boolean`
  `isNeedClientAuth()`
  `void`
  `notifyIfHandshakeFinished()`
  `void`
  `setDebugId(String id)`
  `protected void`
  `tlsEngineHandshakeCompleted()`
  `String`
  `toString()`
  `ByteBuffer`
  `unwrap(ByteBuffer net, ByteBuffer app)`
  `boolean`
  `wantClientAuth()`
  `void`
  `wrap(ByteBuffer app, ByteBuffer net)`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### JcaTLSWrapper

    public JcaTLSWrapper(SSLContext sslc, TLSEventHandler eventHandler, String hostname, int port, boolean clientMode, boolean wantClientAuth)

  - ### JcaTLSWrapper

    public JcaTLSWrapper(SSLContext sslc, TLSEventHandler eventHandler, String hostname, int port, boolean clientMode, boolean wantClientAuth, boolean needClientAuth)
    Creates a new `TLSWrapper` instance.

  - ### JcaTLSWrapper

    public JcaTLSWrapper(SSLContext sslc, TLSEventHandler eventHandler, String remote_hostname, int port, boolean clientMode, boolean wantClientAuth, boolean needClientAuth, String[] enabledCiphers, String[] enabledProtocols)

- ## Method Details

  - ### tlsEngineHandshakeCompleted

    protected void tlsEngineHandshakeCompleted()

  - ### notifyIfHandshakeFinished

    public void notifyIfHandshakeFinished()
    Specified by:
      `notifyIfHandshakeFinished` in interface `TLSWrapper`

  - ### bytesConsumed

    public int bytesConsumed()
    Specified by:
      `bytesConsumed` in interface `TLSWrapper`

  - ### close

    public void close() throws SSLException
    Specified by:
      `close` in interface `TLSWrapper`
    Throws:
      `SSLException`

  - ### getAppBuffSize

    public int getAppBuffSize()
    Specified by:
      `getAppBuffSize` in interface `TLSWrapper`

  - ### getCertificateStatus

    public CertCheckResult getCertificateStatus(boolean revocationEnabled, SSLContextContainerIfc sslContextContainer)
    Specified by:
      `getCertificateStatus` in interface `TLSWrapper`

  - ### getHandshakeStatus

    public SSLEngineResult.HandshakeStatus getHandshakeStatus()
    Specified by:
      `getHandshakeStatus` in interface `TLSWrapper`

  - ### getLocalCertificates

    public Certificate[] getLocalCertificates()
    Specified by:
      `getLocalCertificates` in interface `TLSWrapper`

  - ### getNetBuffSize

    public int getNetBuffSize()
    Specified by:
      `getNetBuffSize` in interface `TLSWrapper`

  - ### getPacketBuffSize

    public int getPacketBuffSize()
    Specified by:
      `getPacketBuffSize` in interface `TLSWrapper`

  - ### getPeerCertificates

    public Certificate[] getPeerCertificates() throws SSLPeerUnverifiedException
    Specified by:
      `getPeerCertificates` in interface `TLSWrapper`
    Throws:
      `SSLPeerUnverifiedException`

  - ### getStatus

    public TLSStatus getStatus()
    Specified by:
      `getStatus` in interface `TLSWrapper`

  - ### getTlsUniqueBindingData

    public byte[] getTlsUniqueBindingData()
    Specified by:
      `getTlsUniqueBindingData` in interface `TLSWrapper`

  - ### isClientMode

    public boolean isClientMode()
    Specified by:
      `isClientMode` in interface `TLSWrapper`

  - ### isNeedClientAuth

    public boolean isNeedClientAuth()
    Specified by:
      `isNeedClientAuth` in interface `TLSWrapper`

  - ### setDebugId

    public void setDebugId(String id)
    Specified by:
      `setDebugId` in interface `TLSWrapper`

  - ### unwrap

    public ByteBuffer unwrap(ByteBuffer net, ByteBuffer app) throws SSLException
    Specified by:
      `unwrap` in interface `TLSWrapper`
    Throws:
      `SSLException`

  - ### wantClientAuth

    public boolean wantClientAuth()
    Specified by:
      `wantClientAuth` in interface `TLSWrapper`

  - ### wrap

    public void wrap(ByteBuffer app, ByteBuffer net) throws SSLException
    Specified by:
      `wrap` in interface `TLSWrapper`
    Throws:
      `SSLException`

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`