Skip to content

Commit

Permalink
Merge pull request #2754 from Infisical/daniel/azure-auth-better-error
Browse files Browse the repository at this point in the history
  • Loading branch information
maidul98 authored Nov 19, 2024
2 parents 8bf7e4c + 31fc64f commit 61d516e
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,9 @@ export const identityAzureAuthServiceFactory = ({
.map((servicePrincipalId) => servicePrincipalId.trim())
.some((servicePrincipalId) => servicePrincipalId === azureIdentity.oid);

if (!isServicePrincipalAllowed) throw new UnauthorizedError({ message: "Service principal not allowed" });
if (!isServicePrincipalAllowed) {
throw new UnauthorizedError({ message: `Service principal '${azureIdentity.oid}' not allowed` });
}
}

const identityAccessToken = await identityAzureAuthDAL.transaction(async (tx) => {
Expand Down

0 comments on commit 61d516e

Please sign in to comment.