Teemu Tapanila bio photo

Teemu Tapanila

CTO of Mallow

Email Twitter LinkedIn Github

This guide shows you how to use Windows Azure Active Directory Access Control (also known as Access Control Service or ACS)

Requirements:

Lets start by configuring the Windows Azure part first.

  1. Open dashboard
  2. Click Active Directory ActiveDirectory
  3. Click New from left bottom and fill in the name and choose region CreateActiveDirectory
  4. Choose your subscription and click Manage from bottomManageActiveDirectory2
  5. Take up your Service Namespace. In my case "tapanilablog" AccessControlService
  6. Click Management Service from left and then ManagementClient AccessControlServiceManagementService
  7. Click Password AccessControlServiceManagementServicePassword
  8. Click Show Password and take up your Password there's needed later AccessControlServiceManagementServicePasswordButton
  9. Close your ACS management page and go back to dashboard
  10. Click Web sites WebSites
  11. Create new web site CreateWebSite
  12. Download the publish profile and take up the url WebSiteDetails

Now the Visual studio part

  1. Create new web project. Check that you are targeting .net 4.5 CreatingEmptyWebProject
  2. Right click your project and choose Identity and Access IdentityAndAccess
  3. Select "Use the Windows Azure Access Control Service" IdentityAndAccessSettings
  4. Click Change from below IdentityAndAccessChange
  5. Enter your ACS namespace and management key that we got before IdentityAndAccessConfigure
  6. Choose which providers you want to use with your application and Enter your realms and click okay IdentityAndAccessProvideAndRealms
  7. Right click project and click Publish PublishingProject
  8. Import your publishing profile PublishingImport
  9. Click Publish PublishPublish
  10. Now it should open your website and automatically redirect you into Live login because that's the only method. After your login is completed it will show you "Server Error in '/' Application. Because we used empty project

Update 29.7.2013: If you have Runtime/Server issues when you have deployed this to Azure follow this guide.