From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adolf Belka To: development@lists.ipfire.org Subject: [PATCH] libcap: Update to 2.50 Date: Thu, 03 Jun 2021 14:20:45 +0200 Message-ID: <20210603122045.683689-1-adolf.belka@ipfire.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2814093577758217610==" List-Id: --===============2814093577758217610== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable - Update from 2.49 to 2.50 - Update rootfile - Version 2.50 failed to install capsh - bug raised for this https://bugzilla.kernel.org/show_bug.cgi?id=3D213261 patch to fix this bug created and used in this build - Changelog Release notes for 2.50 2021-05-24 12:05:16 -0700 Some new capsh features: --explain=3Dcap_foo: describe what cap_foo does (Bug 212451) --suggest=3Dphrase: search all the cap descriptions and describe th= ose that match the phrase Add "keepcaps" module argument support to pam_cap.so (reported by Zolta= n Fridrich. Bug 212945) extend libcap to include cap_prctl() and cap_prctlw() functions to = regain feature parity with Go "cap" package. These are only needed when linki= ng against -lpsx for keepcaps POSIX semantics. this likely requires substantial application changes to make Ambien= t capability support usable in general, but doing our part for the admin. Add a test case for recent kernel fix (Bug 212737) Go pragma fix for convenience functions in "cap" module (reported by Lo= renz Bauer. Bug 212321) Minor man documentation updates Minor build tree improvements (mostly for maintainer) Signed-off-by: Adolf Belka --- config/rootfiles/common/libcap | 4 +- lfs/libcap | 7 ++-- .../libcap-2.50-install_capsh_again.patch | 38 +++++++++++++++++++ 3 files changed, 44 insertions(+), 5 deletions(-) create mode 100644 src/patches/libcap-2.50-install_capsh_again.patch diff --git a/config/rootfiles/common/libcap b/config/rootfiles/common/libcap index a3bfbc157..9aec14f12 100644 --- a/config/rootfiles/common/libcap +++ b/config/rootfiles/common/libcap @@ -1,10 +1,10 @@ #lib/libcap.a lib/libcap.so.2 -lib/libcap.so.2.49 +lib/libcap.so.2.50 #lib/libpsx.a #lib/libpsx.so #lib/libpsx.so.2 -#lib/libpsx.so.2.49 +#lib/libpsx.so.2.50 #lib/pkgconfig/libcap.pc #lib/pkgconfig/libpsx.pc lib/security/pam_cap.so diff --git a/lfs/libcap b/lfs/libcap index fd131949d..610ff474b 100644 --- a/lfs/libcap +++ b/lfs/libcap @@ -24,7 +24,7 @@ =20 include Config =20 -VER =3D 2.49 +VER =3D 2.50 =20 THISAPP =3D libcap-$(VER) DL_FILE =3D $(THISAPP).tar.xz @@ -40,7 +40,7 @@ objects =3D $(DL_FILE) =20 $(DL_FILE) =3D $(DL_FROM)/$(DL_FILE) =20 -$(DL_FILE)_MD5 =3D b43ae3690fe4d2cb32e4d25c0983ecd3 +$(DL_FILE)_MD5 =3D 66a561afa81666236ff973544ff4e864 =20 install : $(TARGET) =20 @@ -70,12 +70,13 @@ $(subst %,%_MD5,$(objects)) : $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) @$(PREBUILD) @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE) + cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/libcap-2.50-install_c= apsh_again.patch # Prevent a static library from being installed cd $(DIR_APP) && sed -i '/install.*STALIBNAME/d' libcap/Makefile cd $(DIR_APP) && make GOLANG=3Dno cd $(DIR_APP) && make install GOLANG=3Dno rm -vf /lib/libcap.so - ln -svf /lib/libcap.so.2.49 /usr/lib/libcap.so + ln -svf /lib/libcap.so.2.50 /usr/lib/libcap.so chmod +x /lib/libcap.so.* @rm -rf $(DIR_APP) @$(POSTBUILD) diff --git a/src/patches/libcap-2.50-install_capsh_again.patch b/src/patches/= libcap-2.50-install_capsh_again.patch new file mode 100644 index 000000000..0ae7520dc --- /dev/null +++ b/src/patches/libcap-2.50-install_capsh_again.patch @@ -0,0 +1,38 @@ +From 1f8d32942be54850a3a89c7b58ba5613b5525c58 Mon Sep 17 00:00:00 2001 +From: "Andrew G. Morgan" +Date: Fri, 28 May 2021 13:41:17 -0700 +Subject: [PATCH] Make capsh an installed binary again + +Bug report from Jan Palus: + + https://bugzilla.kernel.org/show_bug.cgi?id=3D213261 + +Signed-off-by: Andrew G. Morgan +--- + progs/Makefile | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/progs/Makefile b/progs/Makefile +index 313dc4d..3c3dc97 100644 +--- a/progs/Makefile ++++ b/progs/Makefile +@@ -32,14 +32,14 @@ $(BUILD): %: %.o $(DEPS) +=20 + install: all + mkdir -p -m 0755 $(FAKEROOT)$(SBINDIR) +- for p in $(PROGS) ; do \ ++ for p in $(PROGS) capsh ; do \ + install -m 0755 $$p $(FAKEROOT)$(SBINDIR) ; \ + done + ifeq ($(RAISE_SETFCAP),yes) + $(FAKEROOT)$(SBINDIR)/setcap cap_setfcap=3Di $(FAKEROOT)$(SBINDIR)/setcap + endif +=20 +-test: $(PROGS) ++test: $(PROGS) capsh +=20 + capshdoc.h.cf: capshdoc.h ./mkcapshdoc.sh + ./mkcapshdoc.sh > $@ +--=20 +2.32.0.rc2 + --=20 2.31.1 --===============2814093577758217610==--