com.mohiva.play.silhouette.impl.authenticators

SessionAuthenticatorService

Related Docs: object SessionAuthenticatorService | package authenticators

class SessionAuthenticatorService extends AuthenticatorService[SessionAuthenticator] with Logger

The service that handles the session authenticator.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. SessionAuthenticatorService
  2. Logger
  3. AuthenticatorService
  4. AnyRef
  5. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new SessionAuthenticatorService(settings: SessionAuthenticatorSettings, fingerprintGenerator: FingerprintGenerator, clock: Clock)

    settings

    The authenticator settings.

    fingerprintGenerator

    The fingerprint generator implementation.

    clock

    The clock implementation.

Type Members

  1. case class AdditionalHeaders(existing: Headers, additional: Seq[(String, Seq[String])]) extends Headers with Product with Serializable

    Used to add additional headers to the existing headers.

    Used to add additional headers to the existing headers.

    existing

    The existing headers.

    additional

    The additional headers to add.

    Definition Classes
    AuthenticatorService

Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  5. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. def create(loginInfo: LoginInfo)(implicit request: RequestHeader): Future[SessionAuthenticator]

    Creates a new authenticator for the specified login info.

    Creates a new authenticator for the specified login info.

    loginInfo

    The login info for which the authenticator should be created.

    request

    The request header.

    returns

    An authenticator.

    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  7. def discard(authenticator: SessionAuthenticator, result: Future[Result])(implicit request: RequestHeader): Future[Result]

    Removes the authenticator from session.

    Removes the authenticator from session.

    authenticator

    The authenticator instance.

    result

    The result to manipulate.

    request

    The request header.

    returns

    The manipulated result.

    Attributes
    protected[com.mohiva.play.silhouette]
    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  8. def embed(session: Session, request: RequestHeader): RequestHeader

    Overrides the user session in request.

    Overrides the user session in request.

    session

    The session to embed.

    request

    The request header.

    returns

    The manipulated request header.

    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  9. def embed(session: Session, result: Future[Result])(implicit request: RequestHeader): Future[Result]

    Embeds the user session into the result.

    Embeds the user session into the result.

    session

    The session to embed.

    result

    The result to manipulate.

    request

    The request header.

    returns

    The manipulated result.

    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  10. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  11. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. def init(authenticator: SessionAuthenticator)(implicit request: RequestHeader): Future[Session]

    Returns a new user session containing the authenticator.

    Returns a new user session containing the authenticator.

    authenticator

    The authenticator instance.

    request

    The request header.

    returns

    The serialized authenticator value.

    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  16. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  17. val logger: Logger

    A named logger instance.

    A named logger instance.

    Definition Classes
    Logger
  18. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  19. final def notify(): Unit

    Definition Classes
    AnyRef
  20. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  21. def renew(authenticator: SessionAuthenticator, result: Future[Result])(implicit request: RequestHeader): Future[Result]

    Replaces the authenticator in session with a new one.

    Replaces the authenticator in session with a new one. The old authenticator needn't be revoked because we use a stateless approach here. So only one authenticator can be bound to a user session.

    authenticator

    The authenticator to update.

    result

    The result to manipulate.

    request

    The request header.

    returns

    The original or a manipulated result.

    Attributes
    protected[com.mohiva.play.silhouette]
    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  22. def retrieve(implicit request: RequestHeader): Future[Option[SessionAuthenticator]]

    Retrieves the authenticator from request.

    Retrieves the authenticator from request.

    request

    The request header.

    returns

    Some authenticator or None if no authenticator could be found in request.

    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  23. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  24. def toString(): String

    Definition Classes
    AnyRef → Any
  25. def touch(authenticator: SessionAuthenticator): Either[SessionAuthenticator, SessionAuthenticator]

    Touches an authenticator.

    Touches an authenticator.

    An authenticator can use sliding window expiration. This means that the authenticator times out after a certain time if it wasn't used. So to mark an authenticator as used it will be touched on every request to a Silhouette action. If an authenticator should not be touched because of the fact that sliding window expiration is disabled, then it should be returned on the right, otherwise it should be returned on the left. An untouched authenticator needn't be updated later by the update method.

    authenticator

    The authenticator to touch.

    returns

    The touched authenticator on the left or the untouched authenticator on the right.

    Attributes
    protected[com.mohiva.play.silhouette]
    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  26. def update(authenticator: SessionAuthenticator, result: Future[Result])(implicit request: RequestHeader): Future[Result]

    Updates the authenticator and store it in the user session.

    Updates the authenticator and store it in the user session.

    Because of the fact that we store the authenticator client side in the user session, we must update the authenticator in the session on every subsequent request to keep the last used date in sync.

    authenticator

    The authenticator to update.

    result

    The result to manipulate.

    request

    The request header.

    returns

    The original or a manipulated result.

    Attributes
    protected[com.mohiva.play.silhouette]
    Definition Classes
    SessionAuthenticatorServiceAuthenticatorService
  27. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Logger

Inherited from AnyRef

Inherited from Any

Ungrouped