Skip to content

Conversation

@sssd-bot
Copy link

This is an automatic backport of PR#8176 krb5_child: use ERR_CHECK_NEXT_AUTH_TYPE instead of EAGAIN to branch sssd-2-11, created by @sumit-bose.

Please make sure this backport is correct.

Note

The commits were cherry-picked without conflicts.

You can push changes to this pull request

git remote add sssd-bot git@github.com:sssd-bot/sssd.git
git fetch sssd-bot refs/heads/SSSD-sssd-backport-pr8176-to-sssd-2-11
git checkout SSSD-sssd-backport-pr8176-to-sssd-2-11
git push sssd-bot SSSD-sssd-backport-pr8176-to-sssd-2-11 --force

Original commits
7ddb51f - utils: add new error code ERR_CHECK_NEXT_AUTH_TYPE
0adc2e7 - krb5_child: use ERR_CHECK_NEXT_AUTH_TYPE instead of EAGAIN
da82d1d - krb5_child: clarify EAGAIN returned by krb5_get_init_creds_password()

Backported commits

  • 9aff33f - utils: add new error code ERR_CHECK_NEXT_AUTH_TYPE
  • 9e7ab89 - krb5_child: use ERR_CHECK_NEXT_AUTH_TYPE instead of EAGAIN
  • 3a0e67e - krb5_child: clarify EAGAIN returned by krb5_get_init_creds_password()

Original Pull Request Body

This patch used the new error code ERR_CHECK_NEXT_AUTH_TYPE while
processing different authentication types instead of EAGAIN because
EAGAIN might have side effects when returned to the callers.

Resolves: #8108

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request backports a change to replace the generic EAGAIN error code with a more specific ERR_CHECK_NEXT_AUTH_TYPE when iterating through different authentication methods in krb5_child. This improves code clarity and robustness by avoiding potential side effects of using EAGAIN. The changes include defining the new error code and its string representation, and consistently replacing EAGAIN in krb5_child.c where it's used to signal trying the next authentication method. A clarifying comment has also been added to explain the handling of EAGAIN when returned from krb5_get_init_creds_password(), which is a different use case. The changes are correct and a good improvement to the codebase. I have not found any issues.

@sumit-bose sumit-bose force-pushed the SSSD-sssd-backport-pr8176-to-sssd-2-11 branch from 3a0e67e to bf8763a Compare November 28, 2025 09:37
Copy link
Contributor

@ikerexxe ikerexxe left a comment

Choose a reason for hiding this comment

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

LGTM!

This error code should be used if another authentication type should be
checked.

Resolves: SSSD#8108
Reviewed-by: Iker Pedrosa <ipedrosa@redhat.com>
Reviewed-by: Tomáš Halman <thalman@redhat.com>
(cherry picked from commit 7ddb51f)
This patch used the new error code ERR_CHECK_NEXT_AUTH_TYPE while
processing different authentication types instead of EAGAIN because
EAGAIN might have side effects when returned to the callers.

Resolves: SSSD#8108
Reviewed-by: Iker Pedrosa <ipedrosa@redhat.com>
Reviewed-by: Tomáš Halman <thalman@redhat.com>
(cherry picked from commit 0adc2e7)
Reviewed-by: Iker Pedrosa <ipedrosa@redhat.com>
Reviewed-by: Tomáš Halman <thalman@redhat.com>
(cherry picked from commit da82d1d)
@sssd-bot
Copy link
Author

sssd-bot commented Dec 1, 2025

The pull request was accepted by @ikerexxe with the following PR CI status:


🟢 CodeQL (success)
🟢 rpm-build:centos-stream-10-x86_64:upstream (success)
🟢 rpm-build:fedora-41-x86_64:upstream (success)
🟢 rpm-build:fedora-42-x86_64:upstream (success)
🟢 rpm-build:fedora-43-x86_64:upstream (success)
🟢 rpm-build:fedora-rawhide-x86_64:upstream (success)
🟢 Analyze (target) / cppcheck (success)
🟢 Build / make-distcheck (success)
🟢 ci / intgcheck (centos-10) (success)
🟢 ci / intgcheck (fedora-41) (success)
🟢 ci / intgcheck (fedora-42) (success)
🟢 ci / intgcheck (fedora-43) (success)
🟢 ci / intgcheck (fedora-44) (success)
🟢 ci / prepare (success)
🟢 ci / system (centos-10) (success)
🟢 ci / system (fedora-41) (success)
🟢 ci / system (fedora-42) (success)
🟢 ci / system (fedora-43) (success)
🟢 ci / system (fedora-44) (success)
🟢 Static code analysis / codeql (success)
🟢 Static code analysis / pre-commit (success)
🟢 Static code analysis / python-system-tests (success)


There are unsuccessful or unfinished checks. Make sure that the failures are not related to this pull request before merging.

@sssd-bot sssd-bot force-pushed the SSSD-sssd-backport-pr8176-to-sssd-2-11 branch from bf8763a to 455b4e4 Compare December 1, 2025 10:13
@ikerexxe ikerexxe merged commit 67339df into SSSD:sssd-2-11 Dec 1, 2025
9 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants