Caption => DisplayName
This commit is contained in:
parent
742b96d18c
commit
e091bceaa8
|
|
@ -43,7 +43,7 @@ namespace CookieSample
|
||||||
app.UseOAuthAuthentication(new OAuthOptions
|
app.UseOAuthAuthentication(new OAuthOptions
|
||||||
{
|
{
|
||||||
AuthenticationScheme = "Google-AccessToken",
|
AuthenticationScheme = "Google-AccessToken",
|
||||||
Caption = "Google-AccessToken",
|
DisplayName = "Google-AccessToken",
|
||||||
ClientId = "560027070069-37ldt4kfuohhu3m495hk2j4pjp92d382.apps.googleusercontent.com",
|
ClientId = "560027070069-37ldt4kfuohhu3m495hk2j4pjp92d382.apps.googleusercontent.com",
|
||||||
ClientSecret = "n2Q-GEw9RQjzcRbU3qhfTj8f",
|
ClientSecret = "n2Q-GEw9RQjzcRbU3qhfTj8f",
|
||||||
CallbackPath = new PathString("/signin-google-token"),
|
CallbackPath = new PathString("/signin-google-token"),
|
||||||
|
|
@ -86,7 +86,7 @@ namespace CookieSample
|
||||||
app.UseOAuthAuthentication(new OAuthOptions
|
app.UseOAuthAuthentication(new OAuthOptions
|
||||||
{
|
{
|
||||||
AuthenticationScheme = "Microsoft-AccessToken",
|
AuthenticationScheme = "Microsoft-AccessToken",
|
||||||
Caption = "MicrosoftAccount-AccessToken - Requires project changes",
|
DisplayName = "MicrosoftAccount-AccessToken - Requires project changes",
|
||||||
ClientId = "00000000480FF62E",
|
ClientId = "00000000480FF62E",
|
||||||
ClientSecret = "bLw2JIvf8Y1TaToipPEqxTVlOeJwCUsr",
|
ClientSecret = "bLw2JIvf8Y1TaToipPEqxTVlOeJwCUsr",
|
||||||
CallbackPath = new PathString("/signin-microsoft-token"),
|
CallbackPath = new PathString("/signin-microsoft-token"),
|
||||||
|
|
@ -97,7 +97,7 @@ namespace CookieSample
|
||||||
|
|
||||||
app.UseMicrosoftAccountAuthentication(options =>
|
app.UseMicrosoftAccountAuthentication(options =>
|
||||||
{
|
{
|
||||||
options.Caption = "MicrosoftAccount - Requires project changes";
|
options.DisplayName = "MicrosoftAccount - Requires project changes";
|
||||||
options.ClientId = "00000000480FF62E";
|
options.ClientId = "00000000480FF62E";
|
||||||
options.ClientSecret = "bLw2JIvf8Y1TaToipPEqxTVlOeJwCUsr";
|
options.ClientSecret = "bLw2JIvf8Y1TaToipPEqxTVlOeJwCUsr";
|
||||||
options.Scope.Add("wl.emails");
|
options.Scope.Add("wl.emails");
|
||||||
|
|
@ -107,7 +107,7 @@ namespace CookieSample
|
||||||
app.UseOAuthAuthentication(new OAuthOptions
|
app.UseOAuthAuthentication(new OAuthOptions
|
||||||
{
|
{
|
||||||
AuthenticationScheme = "GitHub-AccessToken",
|
AuthenticationScheme = "GitHub-AccessToken",
|
||||||
Caption = "Github-AccessToken",
|
DisplayName = "Github-AccessToken",
|
||||||
ClientId = "8c0c5a572abe8fe89588",
|
ClientId = "8c0c5a572abe8fe89588",
|
||||||
ClientSecret = "e1d95eaf03461d27acd6f49d4fc7bf19d6ac8cda",
|
ClientSecret = "e1d95eaf03461d27acd6f49d4fc7bf19d6ac8cda",
|
||||||
CallbackPath = new PathString("/signin-github-token"),
|
CallbackPath = new PathString("/signin-github-token"),
|
||||||
|
|
@ -118,7 +118,7 @@ namespace CookieSample
|
||||||
app.UseOAuthAuthentication(new OAuthOptions
|
app.UseOAuthAuthentication(new OAuthOptions
|
||||||
{
|
{
|
||||||
AuthenticationScheme = "GitHub",
|
AuthenticationScheme = "GitHub",
|
||||||
Caption = "Github",
|
DisplayName = "Github",
|
||||||
ClientId = "49e302895d8b09ea5656",
|
ClientId = "49e302895d8b09ea5656",
|
||||||
ClientSecret = "98f1bf028608901e9df91d64ee61536fe562064b",
|
ClientSecret = "98f1bf028608901e9df91d64ee61536fe562064b",
|
||||||
CallbackPath = new PathString("/signin-github"),
|
CallbackPath = new PathString("/signin-github"),
|
||||||
|
|
@ -196,7 +196,7 @@ namespace CookieSample
|
||||||
await context.Response.WriteAsync("Choose an authentication scheme: <br>");
|
await context.Response.WriteAsync("Choose an authentication scheme: <br>");
|
||||||
foreach (var type in context.Authentication.GetAuthenticationSchemes())
|
foreach (var type in context.Authentication.GetAuthenticationSchemes())
|
||||||
{
|
{
|
||||||
await context.Response.WriteAsync("<a href=\"?authscheme=" + type.AuthenticationScheme + "\">" + (type.Caption ?? "(suppressed)") + "</a><br>");
|
await context.Response.WriteAsync("<a href=\"?authscheme=" + type.AuthenticationScheme + "\">" + (type.DisplayName ?? "(suppressed)") + "</a><br>");
|
||||||
}
|
}
|
||||||
await context.Response.WriteAsync("</body></html>");
|
await context.Response.WriteAsync("</body></html>");
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ namespace Microsoft.AspNet.Authentication.Facebook
|
||||||
public FacebookOptions()
|
public FacebookOptions()
|
||||||
{
|
{
|
||||||
AuthenticationScheme = FacebookDefaults.AuthenticationScheme;
|
AuthenticationScheme = FacebookDefaults.AuthenticationScheme;
|
||||||
Caption = AuthenticationScheme;
|
DisplayName = AuthenticationScheme;
|
||||||
CallbackPath = new PathString("/signin-facebook");
|
CallbackPath = new PathString("/signin-facebook");
|
||||||
SendAppSecretProof = true;
|
SendAppSecretProof = true;
|
||||||
AuthorizationEndpoint = FacebookDefaults.AuthorizationEndpoint;
|
AuthorizationEndpoint = FacebookDefaults.AuthorizationEndpoint;
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ namespace Microsoft.AspNet.Authentication.Google
|
||||||
public GoogleOptions()
|
public GoogleOptions()
|
||||||
{
|
{
|
||||||
AuthenticationScheme = GoogleDefaults.AuthenticationScheme;
|
AuthenticationScheme = GoogleDefaults.AuthenticationScheme;
|
||||||
Caption = AuthenticationScheme;
|
DisplayName = AuthenticationScheme;
|
||||||
CallbackPath = new PathString("/signin-google");
|
CallbackPath = new PathString("/signin-google");
|
||||||
AuthorizationEndpoint = GoogleDefaults.AuthorizationEndpoint;
|
AuthorizationEndpoint = GoogleDefaults.AuthorizationEndpoint;
|
||||||
TokenEndpoint = GoogleDefaults.TokenEndpoint;
|
TokenEndpoint = GoogleDefaults.TokenEndpoint;
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ namespace Microsoft.AspNet.Authentication.MicrosoftAccount
|
||||||
public MicrosoftAccountOptions()
|
public MicrosoftAccountOptions()
|
||||||
{
|
{
|
||||||
AuthenticationScheme = MicrosoftAccountDefaults.AuthenticationScheme;
|
AuthenticationScheme = MicrosoftAccountDefaults.AuthenticationScheme;
|
||||||
Caption = AuthenticationScheme;
|
DisplayName = AuthenticationScheme;
|
||||||
CallbackPath = new PathString("/signin-microsoft");
|
CallbackPath = new PathString("/signin-microsoft");
|
||||||
AuthorizationEndpoint = MicrosoftAccountDefaults.AuthorizationEndpoint;
|
AuthorizationEndpoint = MicrosoftAccountDefaults.AuthorizationEndpoint;
|
||||||
TokenEndpoint = MicrosoftAccountDefaults.TokenEndpoint;
|
TokenEndpoint = MicrosoftAccountDefaults.TokenEndpoint;
|
||||||
|
|
|
||||||
|
|
@ -44,10 +44,10 @@ namespace Microsoft.AspNet.Authentication.OAuth
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get or sets the text that the user can display on a sign in user interface.
|
/// Get or sets the text that the user can display on a sign in user interface.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string Caption
|
public string DisplayName
|
||||||
{
|
{
|
||||||
get { return Description.Caption; }
|
get { return Description.DisplayName; }
|
||||||
set { Description.Caption = value; }
|
set { Description.DisplayName = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,7 @@ namespace Microsoft.AspNet.Authentication.OpenIdConnect
|
||||||
public OpenIdConnectOptions(string authenticationScheme)
|
public OpenIdConnectOptions(string authenticationScheme)
|
||||||
{
|
{
|
||||||
AuthenticationScheme = authenticationScheme;
|
AuthenticationScheme = authenticationScheme;
|
||||||
Caption = OpenIdConnectDefaults.Caption;
|
DisplayName = OpenIdConnectDefaults.Caption;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -81,10 +81,10 @@ namespace Microsoft.AspNet.Authentication.OpenIdConnect
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get or sets the text that the user can display on a sign in user interface.
|
/// Get or sets the text that the user can display on a sign in user interface.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string Caption
|
public string DisplayName
|
||||||
{
|
{
|
||||||
get { return Description.Caption; }
|
get { return Description.DisplayName; }
|
||||||
set { Description.Caption = value; }
|
set { Description.DisplayName = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ namespace Microsoft.AspNet.Authentication.Twitter
|
||||||
public TwitterOptions()
|
public TwitterOptions()
|
||||||
{
|
{
|
||||||
AuthenticationScheme = TwitterDefaults.AuthenticationScheme;
|
AuthenticationScheme = TwitterDefaults.AuthenticationScheme;
|
||||||
Caption = AuthenticationScheme;
|
DisplayName = AuthenticationScheme;
|
||||||
CallbackPath = new PathString("/signin-twitter");
|
CallbackPath = new PathString("/signin-twitter");
|
||||||
BackchannelTimeout = TimeSpan.FromSeconds(60);
|
BackchannelTimeout = TimeSpan.FromSeconds(60);
|
||||||
}
|
}
|
||||||
|
|
@ -53,10 +53,10 @@ namespace Microsoft.AspNet.Authentication.Twitter
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get or sets the text that the user can display on a sign in user interface.
|
/// Get or sets the text that the user can display on a sign in user interface.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string Caption
|
public string DisplayName
|
||||||
{
|
{
|
||||||
get { return Description.Caption; }
|
get { return Description.DisplayName; }
|
||||||
set { Description.Caption = value; }
|
set { Description.DisplayName = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue