Created
December 17, 2014 15:33
-
-
Save andrewconnell/2d835911b9bb01916c4a to your computer and use it in GitHub Desktop.
Azure AD & ASP.NET MVC - Walk-Through Implementing ADAL & OWIN - SettingsHelper.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Configuration; | |
using System.Linq; | |
using System.Web; | |
namespace SampleMvcAzAuth.Utils { | |
public class SettingsHelper { | |
public static string ClientId { | |
get { return ConfigurationManager.AppSettings["ida:ClientID"]; } | |
} | |
public static string ClientSecret { | |
get { return ConfigurationManager.AppSettings["ida:Password"]; } | |
} | |
public static string AzureAdTenantId { | |
get { return ConfigurationManager.AppSettings["ida:TenantId"]; } | |
} | |
public static string O365DiscoveryServiceEndpoint { | |
get { return "https://api.office.com/discovery/v1.0/me/"; } | |
} | |
public static string O365DiscoveryResourceId { | |
get { return "https://api.office.com/discovery/"; } | |
} | |
public static string AzureAdGraphResourceId { | |
get { return "https://graph.windows.net"; } | |
} | |
public static string AzureADAuthority { | |
get { return string.Format("https://login.windows.net/{0}/", AzureAdTenantId); } | |
} | |
public static string ClaimTypeObjectIdentifier { | |
get { return "http://schemas.microsoft.com/identity/claims/objectidentifier"; } | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment