Skip to content

[Bug Report]: OIDC autodiscovery fails in Azure environment #3206

@ssddanbrown

Description

@ssddanbrown

Describe the Bug

Microsoft can provide the following format at its jwks_uri:

{
      "kty": "RSA",
      "use": "sig",
      "kid": "abcabcabc",
      "x5t": "abcabcabc",
      "n": "xxxxyyyyyzzzz",
      "e": "AQAB",
      "x5c": [
        "aaaabbbbcccc"
      ],
      "issuer": "https://login.microsoftonline.com/xxx-xxx-xxx/v2.0"
    }

We have the following logic to filter keys to the compatible ones:

return array_filter($keys, function (array $key) {
return $key['kty'] === 'RSA' && $key['use'] === 'sig' && $key['alg'] === 'RS256';
});

This fails due to the alg property being non-existent.

Couple of things we need to do:

  • Check MS provided keys against the standard, support their format if we can identity.
  • Update our filtering to not hard fail on potentially non-assured properties (Relevant to the spec)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions