HTML app and aad authentication


To make our HTML app from azure mobile sites work we had to do some fiddling – well beyond the material noted in the download instructions. The issue were all to do zones, hosting trusts, and CORS.

Having run the simple app in iisxpress, before adding authentication, we then created a visual studio website. This we then published to http://odataresohtml.azurewebsites.net/

Next, we added the required authentication code, in javascript. It turns out the the keyword to induce the Azure AD behavior – vs facebook – is “aad” (unlike for the javascript used in the windows store project).

Finally, one has to register a CORS “family” for our mobile azure site – noting that the azurewebsite hosting the javascript code doing the windows creation/destruction (i.e. (odataresohtml.azurewebsites.net) is a suitably privileged member of the family – when it comes to windows, popups, popdowns, data delivery and the like

Screenshot (136)

Now we can pop windows etc.

image

On a kindle it looks like this:

WP_20140312_002

WP_20140312_003

kindle

Advertisements

About home_pw@msn.com

Computer Programmer who often does network administration with focus on security servers. Very strong in Microsoft Azure cloud!
This entry was posted in Azure AD. Bookmark the permalink.