Skip to content

Conversation

@tlupes
Copy link
Contributor

@tlupes tlupes commented Jul 22, 2025

Reload certificates for all client credential based issues

  • You've read the Contributor Guide and Code of Conduct.
  • You've included unit or integration tests for your change, where applicable.
  • You've included inline docs for your change, where applicable.
  • There's an open issue for the PR that you are making. If you'd like to propose a new feature or change, please open an issue to discuss the change or find an existing issue.

Change retry logic to reload certificates on all credential issues, not just revocation/expiration.

Description

The current behavior of the library is to reload and retry certificates in the event that the certificate fails for one of the following two issues:

  • The certificate has been revoked.
  • The certificate has expired.

There is a great many other reasons that authentication can fail that fall outside of these two scenarios. If any of those additional scenarios occur the certificate will never be reloaded.

As a result, if a bad certificate is installed on the machine and picked up, and subsequently rotated, a service restart is needed for the new certificate to be used.

Fixes #3429

@tlupes tlupes requested a review from a team as a code owner July 22, 2025 13:09
@tlupes
Copy link
Contributor Author

tlupes commented Jul 22, 2025

I am not sure how I can run the extended tests locally (I get credential missing issues even without this change). If they aren't run during merge, let me know how I can run them locally :)

@tlupes
Copy link
Contributor Author

tlupes commented Jul 22, 2025

Integration tests all happy locally!

@jmprieur
Copy link
Collaborator

discussed risks with Bogdan for other invalid_client (bad GUID). This is only one retry so taking it

@jmprieur jmprieur merged commit d50a268 into AzureAD:master Jul 30, 2025
5 checks passed
This was referenced Aug 15, 2025
This was referenced Oct 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Reload certificates for all client credential based issues

4 participants