Class OAuthHeaders
- java.lang.Object
-
- com.sodius.oslc.client.oauth.OAuthHeaders
-
public class OAuthHeaders extends Object
Defines headers used to perform authentication challenges between OSLC applications.- Since:
- 1.9.0
-
-
Field Summary
Fields Modifier and Type Field Description static String
WWW_AUTHENTICATE_DOWNSTREAM
The value to set in the WWW-Authenticate header along with theX_JAZZ_WEB_OAUTH_URL
header.static String
X_COM_IBM_TEAM_REPOSITORY_WEB_AUTH_MSG
The response header returned by a Jazz application when the response status is HTTP 200 and content is a login form, to indicate user authentication is required.static String
X_COM_SODIUS_OAUTH_APPROVAL_MODULE_LOCATION
The response header returned by SodiusWillert applications when a request for creating a friend requires a provisional consumer key.static String
X_COM_SODIUS_OAUTH_DANCE_AUTO_START
A request header whose boolean value controls the OAuth dance made for accessing an OSLC remote resource from the OAuth client.static String
X_COM_SODIUS_OAUTH_DOWNSTREAM_REDIRECT_LOCATION
The response header returned by SodiusWillert applications when a request requires a login to a third-party application (i.e: not an OSLC friend).static String
X_COM_SODIUS_OAUTH_REDIRECT_LOCATION
The response header returned by SodiusWillert applications when a request requires a login to a remote OSLC friend application.static String
X_COM_SODIUS_OAUTH_TWO_LEGGED_AUTHENTICATE
The response header returned by SodiusWillert applications when access to a remote application made with a 2-legged OAuth client was rejected.static String
X_JAZZ_WEB_OAUTH_URL
The response header returned by a Jazz application when a request requires an authentication to a third-party.
-
-
-
Field Detail
-
X_COM_SODIUS_OAUTH_DANCE_AUTO_START
public static final String X_COM_SODIUS_OAUTH_DANCE_AUTO_START
A request header whose boolean value controls the OAuth dance made for accessing an OSLC remote resource from the OAuth client.By default, if the client has not yet an OAuth token to access the remote application (i.e. the user hasn't yet authenticated), it will automatically start the OAuth dance. This means it will ask the remote application to generate an OAuth request token and to provide the authorization URL. Setting this header value to
false
makes the client to immediately return HTTP 401 in that case, without starting the OAuth dance and without even reaching the OSLC remote application. This can notably be interesting when requesting a Compact view of a linked OSLC resource, as the user navigates to a page and is not actively requesting anything yet, so an OAuth challenge is not immediately triggered.This header might be set by front-end to instruct its server not to auto start an OAuth dance. On server side, this header should be set as a boolean attribute on the
Resource
object for theOslcClient
to use it, as we don't want the header to be sent to remote application.- Since:
- 1.14.0
- See Also:
- Constant Field Values
-
X_COM_SODIUS_OAUTH_REDIRECT_LOCATION
public static final String X_COM_SODIUS_OAUTH_REDIRECT_LOCATION
The response header returned by SodiusWillert applications when a request requires a login to a remote OSLC friend application.- See Also:
- Constant Field Values
-
X_COM_SODIUS_OAUTH_DOWNSTREAM_REDIRECT_LOCATION
public static final String X_COM_SODIUS_OAUTH_DOWNSTREAM_REDIRECT_LOCATION
The response header returned by SodiusWillert applications when a request requires a login to a third-party application (i.e: not an OSLC friend).- See Also:
- Constant Field Values
-
X_COM_SODIUS_OAUTH_APPROVAL_MODULE_LOCATION
public static final String X_COM_SODIUS_OAUTH_APPROVAL_MODULE_LOCATION
The response header returned by SodiusWillert applications when a request for creating a friend requires a provisional consumer key.- Since:
- 1.11.0
- See Also:
- Constant Field Values
-
X_COM_SODIUS_OAUTH_TWO_LEGGED_AUTHENTICATE
public static final String X_COM_SODIUS_OAUTH_TWO_LEGGED_AUTHENTICATE
The response header returned by SodiusWillert applications when access to a remote application made with a 2-legged OAuth client was rejected. The value of the header is the value of theWWW-Authenticate
header responded by the remote application.- Since:
- 3.7.0
- See Also:
- Constant Field Values
-
X_COM_IBM_TEAM_REPOSITORY_WEB_AUTH_MSG
public static final String X_COM_IBM_TEAM_REPOSITORY_WEB_AUTH_MSG
The response header returned by a Jazz application when the response status is HTTP 200 and content is a login form, to indicate user authentication is required.- See Also:
- Constant Field Values
-
X_JAZZ_WEB_OAUTH_URL
public static final String X_JAZZ_WEB_OAUTH_URL
The response header returned by a Jazz application when a request requires an authentication to a third-party. It contains the URL to log into the third-party application.SodiusWillert applications should also include this response header, along with the
WWW_AUTHENTICATE_DOWNSTREAM
header if:- the original request comes from a Jazz application
- the original request does not accept the HTML media type
- the SodiusWillert application has to request another Jazz application and receives an authentication challenge with this header
- See Also:
- Constant Field Values
-
WWW_AUTHENTICATE_DOWNSTREAM
public static final String WWW_AUTHENTICATE_DOWNSTREAM
The value to set in the WWW-Authenticate header along with theX_JAZZ_WEB_OAUTH_URL
header.- See Also:
- Constant Field Values
-
-