diff --git a/src/AspNet.Security.OAuth.Autodesk/AutodeskAuthenticationHandler.cs b/src/AspNet.Security.OAuth.Autodesk/AutodeskAuthenticationHandler.cs index 6465be2a3..6eb2b2b1f 100644 --- a/src/AspNet.Security.OAuth.Autodesk/AutodeskAuthenticationHandler.cs +++ b/src/AspNet.Security.OAuth.Autodesk/AutodeskAuthenticationHandler.cs @@ -51,7 +51,7 @@ protected override async Task CreateTicketAsync( return new AuthenticationTicket(context.Principal!, context.Properties, Scheme.Name); } - protected override async Task ExchangeCodeAsync(OAuthCodeExchangeContext context) + protected override async Task ExchangeCodeAsync([NotNull] OAuthCodeExchangeContext context) { var tokenRequestParameters = new Dictionary { diff --git a/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/AutodeskTests.cs b/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/AutodeskTests.cs index 3df743306..3c46a75ff 100644 --- a/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/AutodeskTests.cs +++ b/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/AutodeskTests.cs @@ -27,7 +27,6 @@ protected internal override void RegisterAuthentication(AuthenticationBuilder bu [InlineData(ClaimTypes.GivenName, "John")] [InlineData(ClaimTypes.Surname, "Smith")] [InlineData("urn:autodesk:emailverified", "True")] - [InlineData("urn:autodesk:twofactorenabled", "False")] public async Task Can_Sign_In_Using_Autodesk(string claimType, string claimValue) { // Arrange diff --git a/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/bundle.json b/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/bundle.json index eab4ad8d3..182cdf53b 100644 --- a/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/bundle.json +++ b/test/AspNet.Security.OAuth.Providers.Tests/Autodesk/bundle.json @@ -13,16 +13,15 @@ } }, { - "uri": "https://developer.api.autodesk.com/userprofile/v1/users/@me", + "uri": "https://api.userprofile.autodesk.com/userinfo", "contentFormat": "json", "contentJson": { - "userId": "my-id", - "userName": "John Smith", - "firstName": "John", - "lastName": "Smith", - "emailId": "john@john-smith.local", - "emailVerified": true, - "2FaEnabled": false + "sub": "my-id", + "preferred_username": "John Smith", + "given_name": "John", + "family_name": "Smith", + "email": "john@john-smith.local", + "email_verified": true } } ]