在aspnet core 2中配置JwtAuthentication时使用了什么bearerOption.SaveToken属性?
services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
.AddJwtBearer(bearer =>
{
bearer.TokenValidationParameters.IssuerSigningKey = signingKey as SecurityKey;
bearer.TokenValidationParameters.ValidIssuer = Configuration["Jwt:Issuer"];
bearer.TokenValidationParameters.ValidAudience = Configuration["Jwt:Audience"];
bearer.TokenValidationParameters.ClockSkew = TimeSpan.Zero;
bearer.TokenValidationParameters.ValidateLifetime = true;
bearer.TokenValidationParameters.ValidateAudience = true;
bearer.TokenValidationParameters.ValidateIssuer = true;
bearer.TokenValidationParameters.ValidateIssuerSigningKey = true;
bearer.TokenValidationParameters.RequireExpirationTime = true;
bearer.TokenValidationParameters.RequireSignedTokens = true;
// ******
bearer.SaveToken = true;
// ******
});