You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 14, 2019. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+8-5Lines changed: 8 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -94,10 +94,12 @@ There are two projects in this sample. Each needs to be separately registered i
94
94
95
95
#### Configure the TodoListClient project
96
96
97
-
1. Open `MainPage.xaml.cs'.
98
-
2. Find the declaration of `tenant` and replace the value with the name of your Azure AD tenant.
99
-
3. Find the declaration of `clientId` and replace the value with the Client ID from the Azure portal.
100
-
4. Find the declaration of `todoListResourceId` and `todoListBaseAddress` and ensure their values are set properly for your TodoListService project.
97
+
1. Open `app.config'.
98
+
2. Find the app key `ida:Tenant` and replace the value with your AAD tenant name.
99
+
3. Find the app key `ida:ClientId` and replace the value with the Client ID for the TodoListClient from the Azure portal.
100
+
4. Find the app key `ida:RedirectUri` and replace the value with the Redirect URI for the TodoListClient from the Azure portal, for example `http://TodoListClient`.
101
+
5. Find the app key `todo:TodoListResourceId` and replace the value with the App ID URI of the TodoListService, for example `https://<your_tenant_name>/TodoListService`
102
+
6. Find the app key `todo:TodoListBaseAddress` and replace the value with the base address of the TodoListService project.
101
103
102
104
### Step 5: Trust the IIS Express SSL certificate
103
105
@@ -133,11 +135,12 @@ First, in Visual Studio 2013 create an empty solution to host the projects. Th
133
135
134
136
1. In the solution, create a new Windows --> WPF Application called TodoListClient.
135
137
2. Add the (stable) Active Directory Authentication Library (ADAL) NuGet, Microsoft.IdentityModel.Clients.ActiveDirectory, version 1.0.3 (or higher) to the project.
136
-
3. Add assembly references to `System.Net.Http` and `System.Web.Extensions`.
138
+
3. Add assembly references to `System.Net.Http`, `System.Web.Extensions`, and `System.Configuration`.
137
139
4. Add a new class to the project called `TodoItem.cs`. Copy the code from the sample project file of same name into this class, completely replacing the code in the file in the new project.
138
140
5. Add a new class to the project called `CacheHelper.cs`. Copy the code from the sample project file of same name into this class, completely replacing the code in the file in the new project.
139
141
6. Add a new class to the project called `CredManCache.cs`. Copy the code from the sample project file of same name into this class, completely replacing the code in the file in the new project.
140
142
7. Copy the markup from `MainWindow.xaml' in the sample project into the file of same name in the new project, completely replacing the markup in the file in the new project.
141
143
8. Copy the code from `MainWindow.xaml.cs` in the sample project into the file of same name in the new project, completely replacing the code in the file in the new project.
144
+
9. In `app.config` create keys for `ida:AADInstance`, `ida:Tenant`, `ida:ClientId`, `ida:RedirectUri`, `todo:TodoListResourceId`, and `todo:TodoListBaseAddress` and set them accordingly. For the public Azure cloud, the value of `ida:AADInstance` is `https://login.windows.net/{0}`.
142
145
143
146
Finally, in the properties of the solution itself, set both projects as startup projects.
0 commit comments