4

When signing in to Stack-overflow, for example, you get the following consent screen: enter image description here

1.In my consent screen settings I must give my email. How can I make it so that no email is displayed or a non-gmail email address is displayed ?

2.My consent screen asks for email and basic info. I want it to only ask for email. Where in my MVC app I can config the google authentication to only request email permission ?

EDIT: Regarding question 2, I found the answer:

var googleAuthOptions = new GoogleOAuth2AuthenticationOptions();
            googleAuthOptions.Scope.Add("openid email");
Yaron Levi
  • 12,535
  • 16
  • 69
  • 118
  • Short answer is that you can't: What gets asked for is canned in the ASP.NET OAuth code. However, that code is open source, and you could copy bits out of it to do your own implementation - it's not that hard. – slippyr4 Jul 25 '14 at 10:59
  • @slippyr4 I actually managed to do that. Added it to the question. – Yaron Levi Jul 25 '14 at 11:12

0 Answers0