diff --git a/samples/OpenIdConnectSample/Readme.md b/samples/OpenIdConnectSample/Readme.md index 293820759d..846e3f8e6a 100644 --- a/samples/OpenIdConnectSample/Readme.md +++ b/samples/OpenIdConnectSample/Readme.md @@ -1,6 +1,6 @@ # How to set up the sample locally -The OpenIdConnect sample supports multilpe authentication providers. In these instruction, we will explore how to set up this sample with both Azure Active Directory and Google Identity Platform +The OpenIdConnect sample supports multilpe authentication providers. In these instruction, we will explore how to set up this sample with both Azure Active Directory and Google Identity Platform. ## Determine your development environment and a few key variables @@ -13,30 +13,30 @@ If the application is run from command line or terminal, environment variable AS ### Configure with Azure Active Directory 1. Set up a new Azure Active Directory (AAD) in your Azure Subscription. -2. Open the newly created AAD in Azure web portal -3. Navigate to the Applications tab +2. Open the newly created AAD in Azure web portal. +3. Navigate to the Applications tab. 4. Add a new Application to the AAD. Set the "Sign-on URL" to sample application's URL. 5. Naigate to the Application, and click the Configure tab. 6. Find and save the "Client Id". 7. Add a new key in the "Keys" section. Save value of the key, which is the "Client Secret". -8. Click the "View Endpoints" on the drawer, a dialog will shows six endpoint URLs. Copy the "OAuth 2.0 Authorization Endpoint" to a text editor and remove the "/oauth2/authorize" from the string. The remaining part is the __authority URL__. It looks like __https://login.microsoftonline.com/__ +8. Click the "View Endpoints" on the drawer, a dialog will shows six endpoint URLs. Copy the "OAuth 2.0 Authorization Endpoint" to a text editor and remove the "/oauth2/authorize" from the string. The remaining part is the __authority URL__. It looks like `https://login.microsoftonline.com/`. ### Configure with Google Identity Platform -1. Create a new project through [Google APIs](console.developers.google.com) -2. In the sidebar choose "Credentials" +1. Create a new project through [Google APIs](https://console.developers.google.com). +2. In the sidebar choose "Credentials". 3. Navigate to "OAuth consent screen" tab, fill in the project name and save. 4. Navigate to "Credentials" tab. Click "Create credentials". Choose "OAuth client ID". -5. Select "Web application" as the application type. Fill in the "Authorized redirect URIs" with __https://localhost:44318/signin-oidc__ +5. Select "Web application" as the application type. Fill in the "Authorized redirect URIs" with `https://localhost:44318/signin-oidc`. 6. Save the "Client ID" and "Client Secret" shown in the dialog. -7. Save the "Authority URL" for Google Authentication is __https://accounts.google.com/ +7. The "Authority URL" for Google Authentication is `https://accounts.google.com/`. ## Configure the sample application 1. Restore the application. -2. Set user secrets +2. Set user secrets: -``` + ``` dotnet user-secrets set oidc:clientid dotnet user-secrets set oidc:clientsecret dotnet user-secrets set oidc:authority