I have silverlight oob application and need to add Google OAuth 2.0 I'm using this article as reference:
I tried to use WebBrowser Control to send request to Google Auth Service.
Code sample is pretty simple
var url = new Uri("https://accounts.google.com/o/oauth2/auth?
redirect_uri=urn:ietf:wg:oauth:2.0:oob&
response_type=code&
scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.email+https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.profile&
client_id=<my_client_id>");
WebBrowser.Navigate(url);
But I keep getting this error WebBrowser.Navigate Attempted to perform an unauthorized
operation.
I tried http ://localhost
as redirect_uri (result is the same)
Isthere any way to make this work in Silverlight App OOB Version
Finally I have found solution. Just need to check Require Elevated trust when running outside the browser in Out-of-Browser Settings.