Class CustomAuthenticationPolicy
- java.lang.Object
-
- com.oracle.bmc.http.client.internal.ExplicitlySetBmcModel
-
- com.oracle.bmc.apigateway.model.AuthenticationPolicy
-
- com.oracle.bmc.apigateway.model.CustomAuthenticationPolicy
-
@Generated(value="OracleSDKGenerator", comments="API Version: 20190501") public final class CustomAuthenticationPolicy extends AuthenticationPolicy
Use a function to validate a custom header or query parameter sent with the request authentication.A valid policy must specify either tokenHeader or tokenQueryParam.
Note: Objects should always be created or deserialized using theCustomAuthenticationPolicy.Builder
. This model distinguishes fields that are null because they are unset from fields that are explicitly set to null. This is done in the setter methods of theCustomAuthenticationPolicy.Builder
, which maintain a set of all explicitly set fields calledCustomAuthenticationPolicy.Builder.__explicitlySet__
. ThehashCode()
andequals(Object)
methods are implemented to take the explicitly set fields into account. The constructor, on the other hand, does not take the explicitly set fields into account (since the constructor cannot distinguish explicit null from unset null).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CustomAuthenticationPolicy.Builder
-
Nested classes/interfaces inherited from class com.oracle.bmc.apigateway.model.AuthenticationPolicy
AuthenticationPolicy.Type
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static CustomAuthenticationPolicy.Builder
builder()
Create a new builder.boolean
equals(Object o)
List<String>
getCacheKey()
A list of keys from “parameters” attribute value whose values will be added to the cache key.String
getFunctionId()
The OCID of the Oracle Functions function resource.Map<String,String>
getParameters()
A map where key is a user defined string and value is a context expressions whose values will be sent to the custom auth function.String
getTokenHeader()
The name of the header containing the authentication token.String
getTokenQueryParam()
The name of the query parameter containing the authentication token.ValidationFailurePolicy
getValidationFailurePolicy()
int
hashCode()
CustomAuthenticationPolicy.Builder
toBuilder()
String
toString()
String
toString(boolean includeByteArrayContents)
Return a string representation of the object.-
Methods inherited from class com.oracle.bmc.apigateway.model.AuthenticationPolicy
getIsAnonymousAccessAllowed
-
-
-
-
Method Detail
-
builder
public static CustomAuthenticationPolicy.Builder builder()
Create a new builder.
-
toBuilder
public CustomAuthenticationPolicy.Builder toBuilder()
-
getFunctionId
public String getFunctionId()
The OCID of the Oracle Functions function resource.- Returns:
- the value
-
getTokenHeader
public String getTokenHeader()
The name of the header containing the authentication token.- Returns:
- the value
-
getTokenQueryParam
public String getTokenQueryParam()
The name of the query parameter containing the authentication token.- Returns:
- the value
-
getParameters
public Map<String,String> getParameters()
A map where key is a user defined string and value is a context expressions whose values will be sent to the custom auth function.Values should contain an expression. Example: {“foo”: “request.header[abc]”}
- Returns:
- the value
-
getCacheKey
public List<String> getCacheKey()
A list of keys from “parameters” attribute value whose values will be added to the cache key.- Returns:
- the value
-
getValidationFailurePolicy
public ValidationFailurePolicy getValidationFailurePolicy()
-
toString
public String toString()
- Overrides:
toString
in classAuthenticationPolicy
-
toString
public String toString(boolean includeByteArrayContents)
Return a string representation of the object.- Overrides:
toString
in classAuthenticationPolicy
- Parameters:
includeByteArrayContents
- true to include the full contents of byte arrays- Returns:
- string representation
-
equals
public boolean equals(Object o)
- Overrides:
equals
in classAuthenticationPolicy
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classAuthenticationPolicy
-
-