diff options
-rw-r--r-- | main/paxmark/APKBUILD | 8 | ||||
-rw-r--r-- | main/paxmark/paxmark | 17 |
2 files changed, 18 insertions, 7 deletions
diff --git a/main/paxmark/APKBUILD b/main/paxmark/APKBUILD index 4df862bc71..63809acd03 100644 --- a/main/paxmark/APKBUILD +++ b/main/paxmark/APKBUILD @@ -1,6 +1,6 @@ # Maintainer: Timo Teräs <timo.teras@iki.fi> pkgname=paxmark -pkgver=0.5 +pkgver=0.6 pkgrel=0 pkgdesc="Manage PaX marking of executables" url="http://alpinelinux.org" @@ -22,6 +22,6 @@ package() { ln -s paxmark "$pkgdir"/usr/sbin/paxmark.sh || return 1 } -md5sums="08027e79219ed9b6d0e851e70dfa5f87 paxmark" -sha256sums="be68fcf5ac7a84586e9201f0cca977d8cd4f824058f94b5b89e55f8c3f97711c paxmark" -sha512sums="346119a2cc675eb55440057a83fa9aba7a88bfd5bcc851b7ece34f60fbf5836e984f12af30894da3c795a02639ba189f730d403ef669457048c9777e0b2aaeca paxmark" +md5sums="363ee24e0f8eba76033e27d8ddca4e57 paxmark" +sha256sums="1a2c0275f908d5011d4227dcc04eb32c53c63f2a6ce98f6fae0376e4c5e86c83 paxmark" +sha512sums="eaa0a5cc11d3101df075a5291b14fa4865d959ce580f45e2b898be99397d6956aa1e34809a115d1a8ff7b7cc18abdc29cdf2ed36fdbd01c94500a05d248a5291 paxmark" diff --git a/main/paxmark/paxmark b/main/paxmark/paxmark index 562cce78fe..40bac6082f 100644 --- a/main/paxmark/paxmark +++ b/main/paxmark/paxmark @@ -14,10 +14,21 @@ for f in "$@"; do done # Create XATTR_PAX marking using attr -flags="${flags//z}" -[ -n "${flags//[!Ee]}" ] || flags="${flags}e" +local xval="" +[ "${flags//[!P]}" ] && xval="${xval}P" +[ "${flags//[!p]}" -a -z "${flags//[!P]}" ] && xval="${xval}p" +[ "${flags//[!E]}" ] && xval="${xval}E" +[ "${flags//[!e]}" -a -z "${flags//[!E]}" ] && xval="${xval}e" +[ -z "${flags//[!Ee]}" ] && xval="${xval}e" +[ "${flags//[!M]}" ] && xval="${xval}M" +[ "${flags//[!m]}" -a -z "${flags//[!M]}" ] && xval="${xval}m" +[ "${flags//[!R]}" ] && xval="${xval}R" +[ "${flags//[!r]}" -a -z "${flags//[!R]}" ] && xval="${xval}r" +[ "${flags//[!S]}" ] && xval="${xval}S" +[ "${flags//[!s]}" -a -z "${flags//[!S]}" ] && xval="${xval}s" + for f in "$@"; do - attr -q -s pax.flags -V "${flags}" "${f}" >/dev/null 2>&1 && continue + attr -q -s pax.flags -V "${xval}" "${f}" >/dev/null 2>&1 && continue ret=1 done |