8000 Saml ForceAuthn requirement fix. by lhanusov · Pull Request #54369 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Saml ForceAuthn requirement fix. - #54369

Merged
ahus1 merged 1 commit into
keycloak:mainfrom
lhanusov:fix/54339-saml-forceauthn-restart
Oct 29, 2026
Merged

ahus1 merged 1 commit into
keycloak:mainfrom
lhanusov:fix/54339-saml-forceauthn-restart

Conversation

@lhanusov
Copy link
Copy Markdown
Contributor

Closes #54339
Co-authored: Codex noreply@openai.com

@lhanusov
lhanusov requested review from a team as code owners October 27, 2026 11:55
Copilot AI balanced review requested due to automatic review settings October 27, 2026 11:55
@lhanusov
lhanusov force-pushed the fix/54339-saml-forceauthn-restart branch from 32df638 to f230908 Compare October 27, 2026 11:55
Signed-off-by: Lukas Hanusovsky <lhanusov@redhat.com>
@lhanusov
lhanusov force-pushed the fix/54339-saml-forceauthn-restart branch from f230908 to 5dd3901 Compare October 27, 2026 11:56
@lhanusov lhanusov added area/saml SAML 2.0 protocol — IdP and SP roles, artifact binding, ECP, metadata team/core-protocols labels Oct 27, 2026
Copilot AI left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

Static review found no blocking issues in the consistent note-lifecycle change or regression coverage; integration tests were not executed.

No open issues 🎉

What changed in this PR

Fixes #54339 by preserving SAML ForceAuthn across authentication flow restarts, preventing an existing SSO session from bypassing required reauthentication.

Changes:

  • Stores and reads the reauthentication requirement as a restart-persistent client note.
  • Adds POST and Redirect regression tests covering repeated restarts with skip_logout=true, session preservation, and subsequent SSO reuse.
File Description
testsuite/​integration-arquillian/​tests/​base/​src/​test/​java/​org/​keycloak/​testsuite/​saml/​BasicSamlTest.java Adds regression coverage for ForceAuthn across restarts.
services/​src/​main/​java/​org/​keycloak/​protocol/​saml/​SamlService.java Stores ForceAuthn in a client note.
services/​src/​main/​java/​org/​keycloak/​protocol/​saml/​SamlProtocol.java Reads ForceAuthn from the client note.

Review effort: Balanced

Copilot AI balanced review requested due to automatic review settings October 27, 2026 11:57
Copilot AI left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The producer and consumer consistently use restart-persistent notes, and no blocking issues remain; tests were not executed.

No open issues 🎉

Review effort: Balanced

@mposolda mposolda left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lhanusov Thanks!

@ahus1
ahus1 merged commit ff5df30 into keycloak:main Oct 29, 2026
98 checks passed
@mposolda mposolda self-assigned this Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/saml SAML 2.0 protocol — IdP and SP roles, artifact binding, ECP, metadata team/core-protocols

Projects

None yet

4 participants

0