diff --git a/test/Microsoft.AspNet.Authentication.Test/OpenIdConnect/OpenIdConnectHandlerTests.cs b/test/Microsoft.AspNet.Authentication.Test/OpenIdConnect/OpenIdConnectHandlerTests.cs index c3b15e2160..1cb1cb5890 100644 --- a/test/Microsoft.AspNet.Authentication.Test/OpenIdConnect/OpenIdConnectHandlerTests.cs +++ b/test/Microsoft.AspNet.Authentication.Test/OpenIdConnect/OpenIdConnectHandlerTests.cs @@ -4,7 +4,7 @@ using System; using System.Collections.Generic; using System.IdentityModel.Tokens; -using System.IdentityModel.Tokens.OpenIdConnect; +using System.IdentityModel.Tokens.Jwt; using System.Linq; using System.Net.Http; using System.Security.Claims; @@ -27,7 +27,7 @@ namespace Microsoft.AspNet.Authentication.Tests.OpenIdConnect public class OpenIdConnectHandlerTests { private const string nonceForOpenIdConnect = "abc"; - private static SecurityToken specCompliantOpenIdConnect = new OpenIdConnectSecurityToken("issuer", "audience", new List { new Claim("iat", EpochTime.GetIntDate(DateTime.UtcNow).ToString()), new Claim("nonce", nonceForOpenIdConnect) }, DateTime.UtcNow, DateTime.UtcNow + TimeSpan.FromDays(1)); + private static SecurityToken specCompliantOpenIdConnect = new JwtSecurityToken("issuer", "audience", new List { new Claim("iat", EpochTime.GetIntDate(DateTime.UtcNow).ToString()), new Claim("nonce", nonceForOpenIdConnect) }, DateTime.UtcNow, DateTime.UtcNow + TimeSpan.FromDays(1)); private const string ExpectedStateParameter = "expectedState"; /// diff --git a/test/Microsoft.AspNet.Authentication.Test/OpenIdConnectBearer/OpenIdConnectBearerMiddlewareTests.cs b/test/Microsoft.AspNet.Authentication.Test/OpenIdConnectBearer/OpenIdConnectBearerMiddlewareTests.cs index f51fcaaf31..596a6e61fa 100644 --- a/test/Microsoft.AspNet.Authentication.Test/OpenIdConnectBearer/OpenIdConnectBearerMiddlewareTests.cs +++ b/test/Microsoft.AspNet.Authentication.Test/OpenIdConnectBearer/OpenIdConnectBearerMiddlewareTests.cs @@ -27,7 +27,7 @@ namespace Microsoft.AspNet.Authentication.OpenIdConnectBearer options.AutomaticAuthentication = true; options.Authority = "https://login.windows.net/tushartest.onmicrosoft.com"; - options.Audience = "https://TusharTest.onmicrosoft.com/TodoListService-ManualOpenIdConnect"; + options.Audience = "https://TusharTest.onmicrosoft.com/TodoListService-ManualJwt"; options.TokenValidationParameters.ValidateLifetime = false; });