Class OAuth2Authorization


  • public class OAuth2Authorization
    extends java.lang.Object
    represents Authorization Response http://tools.ietf.org/html/rfc6749#section-4.1.2 If the resource owner grants the access request, the authorization server issues an authorization code and delivers it to the client by adding the following parameters to the query component of the redirection URI using the "application/x-www-form-urlencoded" format.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String code
      REQUIRED.
      private java.lang.String state
      REQUIRED if the "state" parameter was present in the client authorization request.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getCode()  
      java.lang.String getState()  
      void setCode​(java.lang.String code)  
      void setState​(java.lang.String state)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • code

        private java.lang.String code
        REQUIRED. The authorization code generated by the authorization server. The authorization code MUST expire shortly after it is issued to mitigate the risk of leaks. A maximum authorization code lifetime of 10 minutes is RECOMMENDED. The client MUST NOT use the authorization code more than once. If an authorization code is used more than once, the authorization server MUST deny the request and SHOULD revoke (when possible) all tokens previously issued based on that authorization code. The authorization code is bound to the client identifier and redirection URI.
      • state

        private java.lang.String state
        REQUIRED if the "state" parameter was present in the client authorization request. The exact value received from the client.
    • Constructor Detail

      • OAuth2Authorization

        public OAuth2Authorization()
    • Method Detail

      • getCode

        public java.lang.String getCode()
      • setCode

        public void setCode​(java.lang.String code)
      • getState

        public java.lang.String getState()
      • setState

        public void setState​(java.lang.String state)