You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Will throw an exception in the case of an "invalid_grant" due to the way that Microsoft.Graph fails to attempt to deserialize the response.
Therefore the OAuthErrorHandler.ThrowIfError call is never made to retrieve the error details.
As yet I am not sure whether this is a Microsoft.Graph error or something that the OneDrive.Sdk should handle.
The example response is:
HTTP/1.1 400 Bad Request
Cache-Control: no-store
Pragma: no-cache
Content-Length: 210
Content-Type: application/json
Server: Microsoft-IIS/8.5
X-WLID-Error: 0x8004100C
X-Content-Type-Options: nosniff
Strict-Transport-Security: max-age=31536000
X-XSS-Protection: 1; mode=block
Date: Tue, 13 Dec 2016 07:57:45 GMT
Connection: close
{"error":"invalid_grant","error_description":"The user could not be authenticated or the grant is expired. The user must first sign in and if needed grant the client application access to the requested scope."}
The text was updated successfully, but these errors were encountered:
oatsoda
changed the title
OAuthHelper.SendTokenRequestAsync cannot retrieve error details from response
OAuthHelper.SendTokenRequestAsync cannot retrieve error details from "invalid_grant" response
Dec 13, 2016
The following line:
https://github.com/OneDrive/onedrive-sdk-dotnet-msa-auth-adapter/blob/master/src/OneDrive.Sdk.Authentication.Common/OAuthHelper.cs#L285
Will throw an exception in the case of an "invalid_grant" due to the way that Microsoft.Graph fails to attempt to deserialize the response.
Therefore the
OAuthErrorHandler.ThrowIfError
call is never made to retrieve the error details.As yet I am not sure whether this is a Microsoft.Graph error or something that the OneDrive.Sdk should handle.
The example response is:
The text was updated successfully, but these errors were encountered: