Skip to content

Commit cbaa20b

Browse files
rujcheCopilot
andauthored
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 93f7bbb commit cbaa20b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aad/configuration/AadResourceServerConfiguration.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ private static void validateTenantId(String tenantId) {
9292
|| "consumers".equalsIgnoreCase(tenantId)) {
9393
throw new IllegalArgumentException(
9494
"For resource server, 'spring.cloud.azure.active-directory.profile.tenant-id' cannot be null, empty, or set to 'common', 'organizations', or 'consumers'. "
95-
+ "This configuration would accept tokens from any Azure AD tenant, creating a security vulnerability. "
96-
+ "Please configure a specific tenant ID to restrict token validation to your organization's tenant only.");
95+
+ "These values are not supported for resource server token validation because a specific tenant ID is required to validate the token 'tid' claim and issuer against a single Azure AD tenant. "
96+
+ "Please configure an explicit tenant ID for your organization's tenant.");
9797
}
9898
}
9999

0 commit comments

Comments
 (0)