FreeBSD Bugzilla – Attachment 250903 Details for
Bug 279255
security/sssd2: Fix the krb5_store_password_if_offline feature
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
proposed security/sssd2 patch
diff (text/plain), 2.62 KB, created by
Mark Johnston
on 2024-05-23 14:49:59 UTC
(
hide
)
Description:
proposed security/sssd2 patch
Filename:
MIME Type:
Creator:
Mark Johnston
Created:
2024-05-23 14:49:59 UTC
Size:
2.62 KB
patch
obsolete
>commit fcaa1c6bf6e63c2482afa6afb2907f9c1e1f25c3 >Author: Mark Johnston <markj@FreeBSD.org> >Date: Fri May 17 10:53:06 2024 -0400 > > security/sssd2: Implement get_active_uid_linux() using linprocfs > > This patch comes from the legacy security/sssd port and is required for > the krb5_store_password_if_offline sssd configuration option to work. > This makes use of linprocfs to look up the UID of each running process. > >diff --git a/security/sssd2/files/patch-src_util_find__uid.c b/security/sssd2/files/patch-src_util_find__uid.c >new file mode 100644 >index 000000000000..5e48c85ea791 >--- /dev/null >+++ b/security/sssd2/files/patch-src_util_find__uid.c >@@ -0,0 +1,40 @@ >+--- src/util/find_uid.c.orig 2024-01-12 12:05:40 UTC >++++ src/util/find_uid.c >+@@ -71,7 +71,7 @@ static errno_t get_uid_from_pid(const pid_t pid, uid_t >+ uint32_t num=0; >+ errno_t error; >+ >+- ret = snprintf(path, PATHLEN, "/proc/%d/status", pid); >++ ret = snprintf(path, PATHLEN, "/compat/linux/proc/%d/status", pid); >+ if (ret < 0) { >+ DEBUG(SSSDBG_CRIT_FAILURE, "snprintf failed\n"); >+ return EINVAL; >+@@ -212,7 +212,7 @@ static errno_t name_to_pid(const char *name, pid_t *pi >+ return EINVAL; >+ } >+ >+- if (num <= 0 || num >= INT_MAX) { >++ if (num < 0 || num >= INT_MAX) { >+ DEBUG(SSSDBG_CRIT_FAILURE, "pid out of range.\n"); >+ return ERANGE; >+ } >+@@ -240,7 +240,7 @@ static errno_t get_active_uid_linux(hash_table_t *tabl >+ hash_key_t key; >+ hash_value_t value; >+ >+- proc_dir = opendir("/proc"); >++ proc_dir = opendir("/compat/linux/proc"); >+ if (proc_dir == NULL) { >+ ret = errno; >+ DEBUG(SSSDBG_CRIT_FAILURE, "Cannot open proc dir.\n"); >+@@ -327,9 +327,9 @@ errno_t get_uid_table(TALLOC_CTX *mem_ctx, hash_table_ >+ >+ errno_t get_uid_table(TALLOC_CTX *mem_ctx, hash_table_t **table) >+ { >+-#ifdef __linux__ >+ int ret; >+ >++#if 1 >+ ret = hash_create_ex(0, table, 0, 0, 0, 0, >+ hash_talloc, hash_talloc_free, mem_ctx, >+ NULL, NULL); >diff --git a/security/sssd2/files/pkg-message.in b/security/sssd2/files/pkg-message.in >index 7e20c0c872d2..c2bc56406527 100644 >--- a/security/sssd2/files/pkg-message.in >+++ b/security/sssd2/files/pkg-message.in >@@ -21,6 +21,9 @@ For additional details, please see the man pages for pam.conf and nsswitch.conf > > An sssd HOWTO is also available: > https://fedorahosted.org/sssd/wiki/HOWTO_Configure_1_0_2 >+ >+The krb5_store_password_if_offline feature requires linprocfs(5) to be mounted >+at /compat/linux/proc. > ================================================================================ > EOM > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 279255
:
250903
|
250904
|
251630
|
251631
|
251633
|
251661
|
251662