Created attachment 256723 [details] proposed patch There is a typo in the patch added in commit ee81c8e455ef. This patch fixes it.
LGTM
Created attachment 256844 [details] proposed patch Updated patch fixes another possible bug: before, if the caller asked us to populate a table, we would return ENOENT if no entries were added, but this is contrary to the previous behaviour.
John, if you have a bit of time, could you please approve the patch? I'm happy to push it to the ports repo myself if that's easier for you.
You can push with Approved by: jhixson (maintainer timeout)
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=7b3028c92e9d74b96c801355ad68b16d9aa22a62 commit 7b3028c92e9d74b96c801355ad68b16d9aa22a62 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2025-01-15 19:59:24 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2025-02-04 17:59:22 +0000 security/sssd2: Fix two bugs in the find_uid patch The UID check was added in commit 9a40ff81f4ea ("security/sssd2: Reimplement UID-finding using sysctl") and is supposed to exclude kernel processes, retaining the behaviour of commit ee81c8e455ef ("security/sssd2: Add patch to enumerate UIDs"). However, it mistakenly skipped over processes with UID 0, which could cause the lookup to fail. Fix the typo. Also return success if the caller asked us to populate a table and no entries were added. This matches the previous behaviour. PR: 284089 Approved by: jhixson (maintainer timeout) Reviewed by: arrowd Sponsored by: Klara, Inc. security/sssd2/Makefile | 1 + security/sssd2/files/patch-src__util__find_uid.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-)