Source code for a step by step guide to publish and consume a Windows Azure WCF Data Service connected to an Azure SQL Database using Azure Access Control Service claims-based authentication. The article describes best practice guidance on exposing an Azure SQL Database on Windows Azure as a WCF Data Service. At the end of this guide, you will create a Windows Azure WCF Data Service using Windows Azure Access Control Service claims-based authentication that connects to an Azure SQL Database. In addition, you will learn how to use a Windows Azure claims-based token to connect to a Windows Azure cloud service.
Lesson 1 - Create a local WCF Data Service that connects to Azure SQL Database
- How to deploy the sample AdventureWorksLT2012_Azure database to Azure SQL Database
- How to restrict a SQL Server User
- How to create a Visual Studio 2012 Windows Azure Cloud Service on localhost
- How to create a Named Resource class to stream an image
- How to encrypt a connection string for testing on localhost
Lesson 2 - Publish a local WCF Data Service to a Windows Azure Cloud Service
- How to publish a Windows Azure Cloud Service
- How to encrypt a connection string for Windows Azure
Lesson 3 - How to implement claims-based authentication using Windows Azure ACS 2.0
- How to configure a user name and password ACS Service Identity
- How to obtain service credentials for an HttpModule
- How to configure web.config for a Windows Azure WCF Data Service
- How to create an Azure custom error page
Lesson 4 - How to configure a Windows Azure WCF Data Service client App for Claims-based authentication
- How to get an ACS SWT token using AzureWebClient.GetTokenFromACS().
- How to get an OData stream using AzureWebClient.OpenRead() passing the SWT token.
- How to create a LINQ query to project the OData stream to a List<List<EntityProperty>>.
- How to save a bitmap from a web response when querying a named resource stream.
- How to use a Login Form to get user name and password
- How to use EncryptString to save sensitive data on the client.