Resolves: rhbz#2167837 - Rebase SSSD for RHEL 9.3

This commit is contained in:
Alexey Tikhonov 2023-05-25 11:02:30 +02:00
parent dacb66a14f
commit 2d39376072
3 changed files with 105 additions and 1 deletions

View File

@ -0,0 +1,71 @@
From 713c646ec054b72cfaadd21f3faaa9c5acb96222 Mon Sep 17 00:00:00 2001
From: Alexey Tikhonov <atikhono@redhat.com>
Date: Tue, 16 May 2023 15:22:04 +0200
Subject: [PATCH] MAN: fix issue with multithread build
When 'make' runs using multiple threads it can build several man pages
in parallel, executing the same '.5.xml.5:' rule. This can result in
a race condition where multiple threads access the same 'sssd_user_name.include'
file.
To avoid this make 'sssd_user_name.include' file a rule dependency.
But "Suffix rules cannot have any prerequisites of their own", and suffix
rules are obsolete anyway, so change it to pattern rules.
---
src/man/Makefile.am | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/src/man/Makefile.am b/src/man/Makefile.am
index ee44dff97..1e51aebfd 100644
--- a/src/man/Makefile.am
+++ b/src/man/Makefile.am
@@ -117,23 +117,23 @@ man_MANS += sssd-files.5
endif # BUILD_FILES_PROVIDER
endif
-SUFFIXES = .1.xml .1 .3.xml .3 .5.xml .5 .8.xml .8
-.1.xml.1:
+$(builddir)/src/man/sssd_user_name.include:
+ @mkdir -p $(builddir)/src/man
+ @echo -n $(SSSD_USER) > $(builddir)/src/man/sssd_user_name.include
+
+%.1: %.1.xml
$(XMLLINT) $(XMLLINT_FLAGS) $<
$(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) $(DOCBOOK_XSLT) $<
-.3.xml.3:
+%.3: %.3.xml
$(XMLLINT) $(XMLLINT_FLAGS) $<
$(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) $(DOCBOOK_XSLT) $<
-.5.xml.5:
- @mkdir -p $(builddir)/src/man
- @echo -n $(SSSD_USER) > $(builddir)/src/man/sssd_user_name.include
+%.5: %.5.xml $(builddir)/src/man/sssd_user_name.include
$(XMLLINT) --path "$(srcdir)/src/man:$(builddir)/src/man" $(XMLLINT_FLAGS) $<
$(XSLTPROC) --path "$(srcdir)/src/man:$(builddir)/src/man" -o $@ $(XSLTPROC_FLAGS) $(DOCBOOK_XSLT) $<
- @rm -f $(builddir)/src/man/sssd_user_name.include
-.8.xml.8:
+%.8: %.8.xml
$(XMLLINT) $(XMLLINT_FLAGS) $<
$(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) $(DOCBOOK_XSLT) $<
@@ -215,6 +215,7 @@ clean-local:
done
rm -f $(man_MANS)
rm -f man.stamp
+ rm -f $(builddir)/src/man/sssd_user_name.include
else
@@ -224,6 +225,7 @@ man.stamp: $(XML_DOC)
clean-local:
rm -f $(man_MANS)
rm -f man.stamp
+ rm -f $(builddir)/src/man/sssd_user_name.include
endif
--
2.38.1

View File

@ -0,0 +1,28 @@
From e5dfa2a8c3cdb4db8749ae1b37cec8185070bc69 Mon Sep 17 00:00:00 2001
From: Sumit Bose <sbose@redhat.com>
Date: Tue, 23 May 2023 12:36:28 +0200
Subject: [PATCH] AD: add missing AD_AT_DOMAIN_NAME for sub-domain search
Reviewed-by: Iker Pedrosa <ipedrosa@redhat.com>
Reviewed-by: Justin Stephenson <jstephen@redhat.com>
(cherry picked from commit 39b6337f32b76842be65802b0b0aa86050c8aa95)
---
src/providers/ad/ad_subdomains.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/providers/ad/ad_subdomains.c b/src/providers/ad/ad_subdomains.c
index db7f1c3c7..a8d1892cc 100644
--- a/src/providers/ad/ad_subdomains.c
+++ b/src/providers/ad/ad_subdomains.c
@@ -1216,7 +1216,7 @@ static void ad_get_slave_domain_connect_done(struct tevent_req *subreq)
int dp_error;
errno_t ret;
const char *attrs[] = { AD_AT_FLATNAME, AD_AT_TRUST_PARTNER,
- AD_AT_SID, AD_AT_TRUST_TYPE,
+ AD_AT_SID, AD_AT_TRUST_TYPE, AD_AT_DOMAIN_NAME,
AD_AT_TRUST_ATTRS, AD_AT_TRUST_DIRECTION, NULL };
req = tevent_req_callback_data(subreq, struct tevent_req);
--
2.38.1

View File

@ -27,7 +27,7 @@
Name: sssd
Version: 2.9.0
Release: 1%{?dist}
Release: 3%{?dist}
Summary: System Security Services Daemon
License: GPLv3+
URL: https://github.com/SSSD/sssd/
@ -35,6 +35,8 @@ Source0: https://github.com/SSSD/sssd/releases/download/%{version}/sssd-%{versio
### Patches ###
Patch0001: 0001-FILE-WATCH-Callback-not-executed-on-link-or-relative.patch
Patch0002: 0002-MAN-fix-issue-with-multithread-build.patch
Patch0003: 0003-AD-add-missing-AD_AT_DOMAIN_NAME-for-sub-domain-sear.patch
### Dependencies ###
@ -1061,6 +1063,9 @@ fi
%systemd_postun_with_restart sssd.service
%changelog
* Thu May 25 2023 Alexey Tikhonov <atikhono@redhat.com> - 2.9.0-3
- Resolves: rhbz#2167837 - Rebase SSSD for RHEL 9.3
* Mon May 15 2023 Alexey Tikhonov <atikhono@redhat.com> - 2.9.0-1
- Resolves: rhbz#2167837 - Rebase SSSD for RHEL 9.3
- Resolves: rhbz#1765354 - [RFE] - Show password expiration warning when IdM users login with SSH keys