Class PowerAuthTokenAuthenticationImpl

  • All Implemented Interfaces:
    io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthAuthentication, io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication, java.io.Serializable, java.security.Principal, org.springframework.security.core.Authentication, org.springframework.security.core.CredentialsContainer

    public class PowerAuthTokenAuthenticationImpl
    extends org.springframework.security.authentication.AbstractAuthenticationToken
    implements io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
    Implementation of the PowerAuthTokenAuthentication interface, with Spring Security objects.
    Author:
    Petr Dvorak, petr@wultra.com
    See Also:
    Serialized Form
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object getCredentials()  
      io.getlime.security.powerauth.http.PowerAuthHttpHeader getHttpHeader()
      Get parsed PowerAuth HTTP header.
      java.lang.String getNonce()
      Get token related nonce.
      java.lang.Object getPrincipal()  
      java.lang.String getTimestamp()
      Get token creation timestamp.
      java.lang.String getTokenDigest()
      Get token digest.
      java.lang.String getTokenId()
      Get token ID.
      java.lang.String getVersion()
      Get PowerAuth protocol version.
      void setHttpHeader​(io.getlime.security.powerauth.http.PowerAuthHttpHeader httpHeader)
      Set parsed PowerAuth HTTP header.
      void setNonce​(java.lang.String nonce)
      Set token related nonce.
      void setTimestamp​(java.lang.String timestamp)
      Set token creation timestamp.
      void setTokenDigest​(java.lang.String tokenDigest)
      Set token digest.
      void setTokenId​(java.lang.String tokenId)
      Set token ID.
      void setVersion​(java.lang.String version)
      Set PowerAuth protocol version.
      • Methods inherited from class org.springframework.security.authentication.AbstractAuthenticationToken

        equals, eraseCredentials, getAuthorities, getDetails, getName, hashCode, isAuthenticated, setAuthenticated, setDetails, toString
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.security.Principal

        implies
    • Constructor Detail

      • PowerAuthTokenAuthenticationImpl

        public PowerAuthTokenAuthenticationImpl()
        Default constructor
    • Method Detail

      • getPrincipal

        public java.lang.Object getPrincipal()
        Specified by:
        getPrincipal in interface org.springframework.security.core.Authentication
      • getCredentials

        public java.lang.Object getCredentials()
        Specified by:
        getCredentials in interface org.springframework.security.core.Authentication
      • getTokenId

        public java.lang.String getTokenId()
        Get token ID.
        Specified by:
        getTokenId in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Returns:
        Token ID.
      • setTokenId

        public void setTokenId​(java.lang.String tokenId)
        Set token ID.
        Specified by:
        setTokenId in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Parameters:
        tokenId - Token ID.
      • getTokenDigest

        public java.lang.String getTokenDigest()
        Get token digest.
        Specified by:
        getTokenDigest in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Returns:
        Token digest.
      • setTokenDigest

        public void setTokenDigest​(java.lang.String tokenDigest)
        Set token digest.
        Specified by:
        setTokenDigest in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Parameters:
        tokenDigest - Token digest.
      • getNonce

        public java.lang.String getNonce()
        Get token related nonce.
        Specified by:
        getNonce in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Returns:
        Nonce.
      • setNonce

        public void setNonce​(java.lang.String nonce)
        Set token related nonce.
        Specified by:
        setNonce in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Parameters:
        nonce - Nonce.
      • getTimestamp

        public java.lang.String getTimestamp()
        Get token creation timestamp.
        Specified by:
        getTimestamp in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Returns:
        Token timestamp.
      • setTimestamp

        public void setTimestamp​(java.lang.String timestamp)
        Set token creation timestamp.
        Specified by:
        setTimestamp in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Parameters:
        timestamp - Token timestamp.
      • getVersion

        public java.lang.String getVersion()
        Get PowerAuth protocol version.
        Specified by:
        getVersion in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Returns:
        PowerAuth protocol version.
      • setVersion

        public void setVersion​(java.lang.String version)
        Set PowerAuth protocol version.
        Specified by:
        setVersion in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Parameters:
        version - PowerAuth protocol version.
      • getHttpHeader

        public io.getlime.security.powerauth.http.PowerAuthHttpHeader getHttpHeader()
        Get parsed PowerAuth HTTP header.
        Specified by:
        getHttpHeader in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Returns:
        PowerAuth HTTP header.
      • setHttpHeader

        public void setHttpHeader​(io.getlime.security.powerauth.http.PowerAuthHttpHeader httpHeader)
        Set parsed PowerAuth HTTP header.
        Specified by:
        setHttpHeader in interface io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthTokenAuthentication
        Parameters:
        httpHeader - PowerAuth HTTP header.