fix: add support for verified Graph API calls for facebook oidc provider #2547
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add support to Facebook OIDC provider for verified Graph API calls.
Facebook allow Apps to enable a security flag that requires proof on all API calls as explained in their documentation
Related issue(s)
The current Facebook provider code does not support this flag and the claims retrieval will silently fail with no claims available. When we check the logs returned by the API call made to the Graph API it returns an error of this type
{ "error": { "message": "API calls from the server require an appsecret_proof argument", "type": "GraphMethodException", "code": 100, "fbtrace_id": "AJWp8p6GrKrNml7iA4eIadU" } }This PR add code to compute the
appsecret_proofand use it on the Graph API call made to retrieve claims.Checklist
If this pull request addresses a security. vulnerability,
I confirm that I got green light (please contact [email protected]) from the maintainers to push the changes.