tigase.auth.impl

## Class ScramSPCallbackHandler

- java.lang.Object
- - tigase.auth.impl.ScramSPCallbackHandler

- All Implemented Interfaces:
    CallbackHandler, AuthRepositoryAware, Aware, DomainAware, SessionAware

      public class ScramSPCallbackHandler
      extends Object
      implements CallbackHandler, AuthRepositoryAware, SessionAware, DomainAware

  Handler for SCRAM with Salted Password.

  Password should be encoded as:

       base64(salt | saltedPassword)

  Where:
  `salt` - 20 bytes,
  `saltedPassword` - 20 bytes.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected BareJID` | `jid`
    `protected Logger` | `log`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ScramSPCallbackHandler()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `handle(Callback[] callbacks)`
    `protected void` | `handleAuthorizeCallback(AuthorizeCallback authCallback)`
    `protected void` | `handleCallback(Callback callback)`
    `protected void` | `handleNameCallback(NameCallback nc)`
    `protected void` | `handlePBKDIterationsCallback(PBKDIterationsCallback callback)`
    `protected void` | `handleSaltCallback(SaltCallback callback)`
    `protected void` | `handleSaltedPasswordCallback(SaltedPasswordCallback callback)`
    `void` | `setAuthRepository(AuthRepository repo)` Sets AuthRepository.
    `void` | `setDomain(String domain)` Sets name of domain from XMPP Stream.
    `void` | `setSession(XMPPResourceConnection session)` Sets XMPP Session.

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

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

- - ### Field Detail

    - #### jid

          protected BareJID jid

    - #### log

          protected Logger log

  - ### Constructor Detail

    - #### ScramSPCallbackHandler

          public ScramSPCallbackHandler()

  - ### Method Detail

    - #### handle

          public void handle(Callback[] callbacks)
                      throws IOException,
                             UnsupportedCallbackException

      Specified by:
        `handle` in interface `CallbackHandler`
      Throws:
        `IOException`
        `UnsupportedCallbackException`

    - #### handleAuthorizeCallback

          protected void handleAuthorizeCallback(AuthorizeCallback authCallback)

    - #### handleCallback

          protected void handleCallback(Callback callback)
                                 throws UnsupportedCallbackException,
                                        IOException

      Throws:
        `UnsupportedCallbackException`
        `IOException`

    - #### handleNameCallback

          protected void handleNameCallback(NameCallback nc)
                                     throws IOException

      Throws:
        `IOException`

    - #### handlePBKDIterationsCallback

          protected void handlePBKDIterationsCallback(PBKDIterationsCallback callback)

    - #### handleSaltCallback

          protected void handleSaltCallback(SaltCallback callback)

    - #### handleSaltedPasswordCallback

          protected void handleSaltedPasswordCallback(SaltedPasswordCallback callback)

    - #### setAuthRepository

          public void setAuthRepository(AuthRepository repo)

      Description copied from interface: `AuthRepositoryAware`
      Sets AuthRepository.
      Specified by:
        `setAuthRepository` in interface `AuthRepositoryAware`
      Parameters:
        `repo` - AuthRepository.

    - #### setDomain

          public void setDomain(String domain)

      Description copied from interface: `DomainAware`
      Sets name of domain from XMPP Stream.
      Specified by:
        `setDomain` in interface `DomainAware`
      Parameters:
        `domain` - domain name

    - #### setSession

          public void setSession(XMPPResourceConnection session)

      Description copied from interface: `SessionAware`
      Sets XMPP Session.
      Specified by:
        `setSession` in interface `SessionAware`
      Parameters:
        `session` - XMPP session.

Copyright © 2018 "Tigase, Inc.". All rights reserved.