Class AadTrustedIssuerRepository
- java.lang.Object
-
- com.azure.spring.cloud.autoconfigure.aad.AadTrustedIssuerRepository
-
- Direct Known Subclasses:
AadB2cTrustedIssuerRepository
public class AadTrustedIssuerRepository extends Object
A tenant id is used to construct the trusted issuer repository.
-
-
Constructor Summary
Constructors Constructor Description AadTrustedIssuerRepository(String tenantId)Creates a new instance ofAadTrustedIssuerRepository.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddSpecialOidcIssuerLocationMap(String issuer, String oidcIssuerLocation)Adds a trusted issuer.booleanaddTrustedIssuer(String... issuers)Adds trusted issuers.StringgetSpecialOidcIssuerLocation(String issuer)Gets the issuer's special OIDC issuer location.Set<String>getTrustedIssuers()Gets the set of trusted issuers.booleanhasSpecialOidcIssuerLocation(String issuer)Whether the issuer has a special OIDC issuer location.booleanisTrusted(String issuer)Whether the issuer is trusted.protected StringresolveBaseUri(String baseUri)Resolve the base uri to get scheme and host.
-
-
-
Field Detail
-
tenantId
protected String tenantId
The tenant ID
-
-
Constructor Detail
-
AadTrustedIssuerRepository
public AadTrustedIssuerRepository(String tenantId)
Creates a new instance ofAadTrustedIssuerRepository.- Parameters:
tenantId- the tenant ID
-
-
Method Detail
-
getTrustedIssuers
public Set<String> getTrustedIssuers()
Gets the set of trusted issuers.- Returns:
- the set of trusted issuers
-
addTrustedIssuer
public boolean addTrustedIssuer(String... issuers)
Adds trusted issuers.- Parameters:
issuers- the issuers- Returns:
- whether the issuers were added
-
addSpecialOidcIssuerLocationMap
public void addSpecialOidcIssuerLocationMap(String issuer, String oidcIssuerLocation)
Adds a trusted issuer.- Parameters:
issuer- the issueroidcIssuerLocation- the OIDC issuer location
-
isTrusted
public boolean isTrusted(String issuer)
Whether the issuer is trusted.- Parameters:
issuer- the issuer- Returns:
- whether the issuer is trusted
-
hasSpecialOidcIssuerLocation
public boolean hasSpecialOidcIssuerLocation(String issuer)
Whether the issuer has a special OIDC issuer location.- Parameters:
issuer- the issuer- Returns:
- whether the issuer has a special OIDC issuer location
-
getSpecialOidcIssuerLocation
public String getSpecialOidcIssuerLocation(String issuer)
Gets the issuer's special OIDC issuer location.- Parameters:
issuer- the issuer- Returns:
- the issuer's special OIDC issuer location
-
resolveBaseUri
protected String resolveBaseUri(String baseUri)
Resolve the base uri to get scheme and host.- Parameters:
baseUri- baseUri Base uri in the configuration file.- Returns:
- the parsed base uri.
- Throws:
RuntimeException- thrown if the uri is not valid.
-
-