{ "name": "libcap", "version": "2.78", "summary": "libcap: POSIX capabilities of processes and files (libcap, libpsx) with setcap, getcap, getpcaps and capsh", "category": "library", "license": "BSD-3-Clause OR GPL-2.0-only", "homepage": "https://sites.google.com/site/fullycapable/", "source": { "url": "https://mirrors.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-2.78.tar.xz", "sha256": "0d621e562fd932ccf67b9660fb018e468a683d7b827541df27813228c996bb11" }, "watch": {"kind": "index", "url": "https://mirrors.kernel.org/pub/linux/libs/security/linux-privs/libcap2/", "regex": "libcap-([0-9]+(?:\\.[0-9]+)+)\\.tar\\.xz", "checksum": "https://mirrors.kernel.org/pub/linux/libs/security/linux-privs/libcap2/sha256sums.asc"}, "deps": [], "env_packages": [], "static": true, "nss": true, "check": "t=$(mktemp -d) && sbin/capsh --decode=0x400 | has -x '0x0000000000000400=cap_net_bind_service' && check_lib libcap sys/capability.h 'cap_t c = cap_from_text(\"cap_net_bind_service,cap_net_raw=ep\"); char *s; cap_flag_value_t f; if (!c) return 1; s = cap_to_text(c, NULL); if (cap_get_flag(c, CAP_NET_RAW, CAP_EFFECTIVE, &f) || f != CAP_SET) return 2; if (cap_get_flag(c, CAP_SYS_ADMIN, CAP_PERMITTED, &f) || f != CAP_CLEAR) return 3; printf(\"libcap: %s\\n\", s); return strcmp(s, \"cap_net_bind_service,cap_net_raw=ep\")' > \"$t/lib\" && cp /bin/true \"$t/prog\" && sbin/setcap cap_net_bind_service=ep \"$t/prog\" && sbin/getcap \"$t/prog\" | has 'cap_net_bind_service=ep' && echo \"libcap 2.78: a capability set parsed and printed back through check_lib; setcap and getcap on a file; capsh decodes a mask\"" }