entra-live-check: support a confidential-client app registration - #8
Merged
Merged
Conversation
`entra-live-check` has been RED on main since 2026-08-04 — nine consecutive runs.
It is not a flake and not a code regression; the tenant's app registration stopped
being treated as a public client, so the password grant is refused:
thread 'main' panicked at auth-oidc/examples/entra_live_check.rs:60:5:
Entra rejected the real password grant (401 Unauthorized): {"error":"invalid_client",
"error_codes":[7000218],"error_description":"AADSTS7000218: The request body must
contain the following parameter: 'client_assertion' or 'client_secret'. ..."}
A public client sends no secret; a confidential one must. Which of the two an app
registration is comes down to its "Allow public client flows" setting, and Entra
reports the mismatch as AADSTS7000218 without ever naming that setting — so the
failure gave no route to a fix. The example now sends `client_secret` when an
`ENTRA_CLIENT_SECRET` is provisioned and omits it when it is not, covering both
shapes, and the assertion message names AADSTS7000218 and both remedies.
THIS ALONE DOES NOT TURN THE CHECK GREEN. It only makes the fix possible without
another code change. One of these must still happen on the tenant side:
- re-enable "Allow public client flows" on the app registration, or
- provision an ENTRA_CLIENT_SECRET repo secret.
Until then the check stays red, and it should stay red — it is reporting a real
loss of live-IdP coverage, not noise.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
entra-live-checkhas been red on main since 2026-08-04 — nine consecutive runs. Not a flake, not a code regression: the tenant's app registration stopped being treated as a public client, so the password grant is refused.A public client sends no secret; a confidential one must. Which one an app registration is comes down to its Allow public client flows setting, and Entra reports the mismatch as AADSTS7000218 without ever naming that setting — so the failure gave no route to a fix.
This sends
client_secretwhen anENTRA_CLIENT_SECRETis provisioned and omits it when it is not, covering both shapes, and the assertion message now names AADSTS7000218 and both remedies.This does not turn the check green on its own
It only makes the fix possible without another code change. One of these still has to happen tenant-side:
ENTRA_CLIENT_SECRETrepo secret.Until then the check stays red — and it should. It is reporting a genuine loss of live-IdP coverage, not noise. Do not merge this expecting green; merge it once one of the two above is done, so the very next push to
mainproves it.The workflow only fires on push to
main, so this PR's own CI cannot exercise it.