Application (client) ID not changing and points to old client id -AADSTS700016

Vijayarajan Vivek 96 Reputation points
2021-10-30T14:32:53.36+00:00

I have a blazor server application which uses identity authentication to Azure AD and works great.

Now I have created a new app registration and changed application config (appsettings.json) to point to new client id but sign in url still points to old client id and finally getting AADSTS700016

old client id: 1ac83815-948a-4cca-b91d-032541fa48f8
new client id : 37aaaf79-034c-4aa2-8422-38f79df5e0c5

here is my appsettings.json

and see client id on my singin url
145468-image.png
![145201-image.png][2] [2]: /api/attachments/145201-image.png?platform=QnA

Can you help me resolving this mystery.

Thanks in advance.

Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,381 questions
0 comments No comments
{count} votes

Accepted answer
  1. Vijayarajan Vivek 96 Reputation points
    2021-11-01T12:55:37.81+00:00

    It worked after a fresh publish and deployment with new client id - but why? For an appsettings.json change why do we need to do a release?

    I have almost spend a day trying out different settings change , reset IIS , reset web app but nothing worked.

    If thats the case then please document it stating that if you are pointing your app to a new registration then instead of changing appsettings.json do a fresh release.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Siva-kumar-selvaraj 15,546 Reputation points
    2021-11-01T07:43:57.817+00:00

    Hello @Vijayarajan Vivek ,

    Thanks for reaching out.

    This seems to be some cache or project might have not rebuild after updating with new clientID due to which changes have not taking place, wondering did you try rebuilding your project just after updating new ClientId ?

    I had referred to this article to build my test Blazor app to test out behavior and found everything working as expected without any issue even after updating new ClientId as shown below and rebuild project using following .NET CLI dotnet run --framework netcoreapp3.1

    145413-image.png

    Hope this helps.

    ------
    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.

    0 comments No comments