Skip navigation links

Oracle Fusion Middleware Java API Reference for the Oracle Access Management OAuth Service
11g Release 2 Patch Set 3 (11.1.2.3)

E59498-01


oracle.security.idaas.oauth.sdk.request
Class RevocationRequest

java.lang.Object
  extended by oracle.security.idaas.oauth.sdk.request.OAuthRestRequest
      extended by oracle.security.idaas.oauth.sdk.request.RevocationRequest


public class RevocationRequest
extends OAuthRestRequest

Class dedicated to terminate a token.
There are 2 ways to terminate a token depending on the client information the user gets.

The grant type to be used to build such request is always OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_USER_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_RESOURCE_ACCESS_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_CLIENT_TOKEN_JWT.


Constructor Summary

RevocationRequest()
          Initializes a basic Access Token request without any parameters.
RevocationRequest(java.util.Map<java.lang.String,java.lang.String> header, java.util.Map<java.lang.String,java.lang.String> query)
          Initializes the Access Token request using the given parameters.
RevocationRequest(java.lang.String grantType, java.lang.String assertion, ClientIdSecretPair clientCredentials)
          Constructor dedicated to request the termination of a token using a client credentials.
RevocationRequest(java.lang.String grantType, java.lang.String assertion, java.lang.String clientAssertionType, java.lang.String clientAssertion)
          Constructor dedicated to request the termination of a token using a client assertion (value/type pair).

  Method Summary

 java.lang.String getAssertion()
          Returns the token value to be terminated.
 java.lang.String getClientAssertion()
          Returns the client_assertion
 java.lang.String getClientAssertionType()
          Returns the client_assertion_type
 ClientIdSecretPair getClientCredentials()
          Returns the client id and secret.
 java.lang.String getGrantType()
          Returns the grant_type
 boolean isJwtClientAssertion()
          Return true if the client assertion is a JWT one.
 boolean isSamlClientAssertion()
          Return true if the client assertion is a SAML one.
 void setAssertion(java.lang.String assertion)
          Updates the token value to be terminated.
 void setClientAssertion(java.lang.String clientAssertion)
          Updates the client_assertion
 void setClientAssertionType(java.lang.String clientAssertionType)
          Updates the Client Assertion Type.
 void setClientCredentials(ClientIdSecretPair clientCredentials)
          Updates the client id and secret
 void setGrantType(java.lang.String grantType)
          Updates the grant_type.

  Methods inherited from class oracle.security.idaas.oauth.sdk.request.OAuthRestRequest

addHeader, addQuery, clearAll, clearHeader, clearQuery, getHeader, getHeader, getQuery, getQuery, getQueryMap, isNullOrEmpty, setHeader, setQuery

  Methods inherited from class java.lang.Object

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

 

Constructor Detail

RevocationRequest

public RevocationRequest()
Initializes a basic Access Token request without any parameters.

RevocationRequest

public RevocationRequest(java.util.Map<java.lang.String,java.lang.String> header,
                         java.util.Map<java.lang.String,java.lang.String> query)
Initializes the Access Token request using the given parameters.
Parameters:
header - list of name/value parameters for request header
query - list of name/value parameters to fit in the query part of the request

RevocationRequest

public RevocationRequest(java.lang.String grantType,
                         java.lang.String assertion,
                         java.lang.String clientAssertionType,
                         java.lang.String clientAssertion)
                  throws java.lang.IllegalArgumentException
Constructor dedicated to request the termination of a token using a client assertion (value/type pair).
Parameters:
grantType - only accepts OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_USER_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_RESOURCE_ACCESS_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_CLIENT_TOKEN_JWT
assertion - token value to be terminated
clientAssertionType - accept only OAuthSdkConstants.SAML_CLIENT_ASSERTION_TYPE or OAuthSdkConstants.JWT_CLIENT_ASSERTION_TYPE
clientAssertion - client assertion allowed to terminate the token, see also ClientAssertionTokenRequest
Throws:
java.lang.IllegalArgumentException - when invalid argument is provided

RevocationRequest

public RevocationRequest(java.lang.String grantType,
                         java.lang.String assertion,
                         ClientIdSecretPair clientCredentials)
                  throws java.lang.IllegalArgumentException
Constructor dedicated to request the termination of a token using a client credentials.
Parameters:
grantType - only accepts OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_USER_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_RESOURCE_ACCESS_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_CLIENT_TOKEN_JWT
assertion - token value to be terminated
clientCredentials - client credentials allowed to terminate the token
Throws:
java.lang.IllegalArgumentException - when invalid parameter

Method Detail

getGrantType

public java.lang.String getGrantType()
Returns the grant_type
Returns:
grant_type

setGrantType

public void setGrantType(java.lang.String grantType)
Updates the grant_type. Accepts only:
Parameters:
grantType - accept only OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_USER_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_RESOURCE_ACCESS_TOKEN_JWT or OAuthSdkConstants.ORACLE_IDM_GRANT_TYPE_CLIENT_TOKEN_JWT

getAssertion

public java.lang.String getAssertion()
Returns the token value to be terminated.
Returns:
assertion

setAssertion

public void setAssertion(java.lang.String assertion)
Updates the token value to be terminated.
Parameters:
assertion - token value

getClientAssertionType

public java.lang.String getClientAssertionType()
Returns the client_assertion_type
Returns:
client_assertion_type

setClientAssertionType

public void setClientAssertionType(java.lang.String clientAssertionType)
Updates the Client Assertion Type. Accepts only:
Parameters:
clientAssertionType - type of the client assertion

getClientAssertion

public java.lang.String getClientAssertion()
Returns the client_assertion
Returns:
client_assertion

setClientAssertion

public void setClientAssertion(java.lang.String clientAssertion)
Updates the client_assertion
Parameters:
clientAssertion - string value of the client assertion

isJwtClientAssertion

public boolean isJwtClientAssertion()
Return true if the client assertion is a JWT one.
Returns:
true for JWT

isSamlClientAssertion

public boolean isSamlClientAssertion()
Return true if the client assertion is a SAML one.
Returns:
true for SAML

getClientCredentials

public ClientIdSecretPair getClientCredentials()
Returns the client id and secret.
Returns:
client id and secret

setClientCredentials

public void setClientCredentials(ClientIdSecretPair clientCredentials)
                          throws java.lang.IllegalArgumentException
Updates the client id and secret
Parameters:
clientCredentials - client information
Throws:
java.lang.IllegalArgumentException - when null parameter

Skip navigation links

Copyright (c) 2014, 2015,
Oracle and/or its affiliates. All Rights Reserved.