AuthenticationProviderProperties Class
- java.
lang. Object - com.
azure. resourcemanager. network. models. AuthenticationProviderProperties
- com.
Implements
public final class AuthenticationProviderProperties
implements JsonSerializable<AuthenticationProviderProperties>
Properties for authentication provider configuration. A policy must configure either JWT validation fields or user sign-in fields; the two configurations are mutually exclusive and cannot be combined.
Constructor Summary
| Constructor | Description |
|---|---|
| AuthenticationProviderProperties() |
Creates an instance of Authentication |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
| String |
audience()
Get the audience property: The intended audience for the JWT. |
| String |
clientId()
Get the client |
| String |
clientSecret()
Get the client |
|
static
Authentication |
fromJson(JsonReader jsonReader)
Reads an instance of Authentication |
| String |
issuer()
Get the issuer property: The absolute HTTPS URL of the Secure Token Service. |
| String |
jwksUri()
Get the jwks |
| List<String> |
scope()
Get the scope property: The scopes used by an application during authentication to authorize access to a user's details. |
| String |
sessionCookieName()
Get the session |
| String |
sessionTimeout()
Get the session |
|
Json |
toJson(JsonWriter jsonWriter) |
| void |
validate()
Validates the instance. |
|
Authentication |
withAudience(String audience)
Set the audience property: The intended audience for the JWT. |
|
Authentication |
withClientId(String clientId)
Set the client |
|
Authentication |
withClientSecret(String clientSecret)
Set the client |
|
Authentication |
withIssuer(String issuer)
Set the issuer property: The absolute HTTPS URL of the Secure Token Service. |
|
Authentication |
withJwksUri(String jwksUri)
Set the jwks |
|
Authentication |
withScope(List<String> scope)
Set the scope property: The scopes used by an application during authentication to authorize access to a user's details. |
|
Authentication |
withSessionCookieName(String sessionCookieName)
Set the session |
|
Authentication |
withSessionTimeout(String sessionTimeout)
Set the session |
Methods inherited from java.lang.Object
Constructor Details
AuthenticationProviderProperties
public AuthenticationProviderProperties()
Creates an instance of AuthenticationProviderProperties class.
Method Details
audience
public String audience()
Get the audience property: The intended audience for the JWT. Only a single audience value is supported in this API version. Example: https://audience.com/\{application-id\}.
Returns:
clientId
public String clientId()
Get the clientId property: The Application (client) ID for the related application registered in Microsoft Entra ID, formatted as a GUID.
Returns:
clientSecret
public String clientSecret()
Get the clientSecret property: The absolute HTTPS Key Vault secret URL identifying the client secret used for authentication. This property is required for user sign-in policies. It holds only the Key Vault reference; the secret value itself is never accepted or returned by this API and is read from Key Vault at runtime using the resource's user-assigned identity. The secret value stored in Key Vault can contain up to 4096 characters. Example: https://myvault.vault.azure.net/secrets/mysecret.
Returns:
fromJson
public static AuthenticationProviderProperties fromJson(JsonReader jsonReader)
Reads an instance of AuthenticationProviderProperties from the JsonReader.
Parameters:
Returns:
Throws:
issuer
public String issuer()
Get the issuer property: The absolute HTTPS URL of the Secure Token Service. Include a trailing slash at the end of the value. Example: https://login.microsoftonline.com/\{Microsoft Entra Tenant ID}/.
Returns:
jwksUri
public String jwksUri()
Get the jwksUri property: The JSON Web Key Set (JWKS) URI used to retrieve the public keys for JWT validation. Example: https://login.microsoftonline.com/\{Microsoft Entra Tenant ID}/discovery/v2.0/keys.
Returns:
scope
public List<String> scope()
Get the scope property: The scopes used by an application during authentication to authorize access to a user's details. A maximum of 10 scopes is supported, each scope can contain up to 128 characters, and all scopes can contain up to 256 characters combined.
Returns:
sessionCookieName
public String sessionCookieName()
Get the sessionCookieName property: The name of the session cookie used for user authentication. Applicable to the Application Gateway post-OIDC workflow.
Returns:
sessionTimeout
public String sessionTimeout()
Get the sessionTimeout property: The timeout of the session cookie used for user authentication. The service accepts and returns this value as a string containing a base-10 unsigned integer number of seconds with no sign, decimal point, unit suffix, or whitespace (for example `86400`). The supported range is 1 to 604800 seconds, and the default is 86400 seconds. Applicable to the Application Gateway post-OIDC workflow.
Returns:
toJson
validate
public void validate()
Validates the instance.
withAudience
public AuthenticationProviderProperties withAudience(String audience)
Set the audience property: The intended audience for the JWT. Only a single audience value is supported in this API version. Example: https://audience.com/\{application-id\}.
Parameters:
Returns:
withClientId
public AuthenticationProviderProperties withClientId(String clientId)
Set the clientId property: The Application (client) ID for the related application registered in Microsoft Entra ID, formatted as a GUID.
Parameters:
Returns:
withClientSecret
public AuthenticationProviderProperties withClientSecret(String clientSecret)
Set the clientSecret property: The absolute HTTPS Key Vault secret URL identifying the client secret used for authentication. This property is required for user sign-in policies. It holds only the Key Vault reference; the secret value itself is never accepted or returned by this API and is read from Key Vault at runtime using the resource's user-assigned identity. The secret value stored in Key Vault can contain up to 4096 characters. Example: https://myvault.vault.azure.net/secrets/mysecret.
Parameters:
Returns:
withIssuer
public AuthenticationProviderProperties withIssuer(String issuer)
Set the issuer property: The absolute HTTPS URL of the Secure Token Service. Include a trailing slash at the end of the value. Example: https://login.microsoftonline.com/\{Microsoft Entra Tenant ID}/.
Parameters:
Returns:
withJwksUri
public AuthenticationProviderProperties withJwksUri(String jwksUri)
Set the jwksUri property: The JSON Web Key Set (JWKS) URI used to retrieve the public keys for JWT validation. Example: https://login.microsoftonline.com/\{Microsoft Entra Tenant ID}/discovery/v2.0/keys.
Parameters:
Returns:
withScope
public AuthenticationProviderProperties withScope(List<String> scope)
Set the scope property: The scopes used by an application during authentication to authorize access to a user's details. A maximum of 10 scopes is supported, each scope can contain up to 128 characters, and all scopes can contain up to 256 characters combined.
Parameters:
Returns:
withSessionCookieName
public AuthenticationProviderProperties withSessionCookieName(String sessionCookieName)
Set the sessionCookieName property: The name of the session cookie used for user authentication. Applicable to the Application Gateway post-OIDC workflow.
Parameters:
Returns:
withSessionTimeout
public AuthenticationProviderProperties withSessionTimeout(String sessionTimeout)
Set the sessionTimeout property: The timeout of the session cookie used for user authentication. The service accepts and returns this value as a string containing a base-10 unsigned integer number of seconds with no sign, decimal point, unit suffix, or whitespace (for example `86400`). The supported range is 1 to 604800 seconds, and the default is 86400 seconds. Applicable to the Application Gateway post-OIDC workflow.
Parameters:
Returns: