d82a5ade0b
Fix CVE-2020-5291: Bubblewrap (bwrap) before version 0.4.1, if installed in setuid mode and the kernel supports unprivileged user namespaces, then the `bwrap --userns2` option can be used to make the setuid process keep running as root while being traceable. This can in turn be used to gain root permissions. Note that this only affects the combination of bubblewrap in setuid mode (which is typically used when unprivileged user namespaces are not supported) and the support of unprivileged user namespaces. Also update indentation of hash file (two spaces) Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> Reviewed-by: Adrian Perez de Castro <aperez@igalia.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
41 lines
1.1 KiB
Makefile
41 lines
1.1 KiB
Makefile
################################################################################
|
|
#
|
|
# bubblewrap
|
|
#
|
|
################################################################################
|
|
|
|
BUBBLEWRAP_VERSION = 0.4.1
|
|
BUBBLEWRAP_SITE = https://github.com/containers/bubblewrap/releases/download/v$(BUBBLEWRAP_VERSION)
|
|
BUBBLEWRAP_SOURCE = bubblewrap-$(BUBBLEWRAP_VERSION).tar.xz
|
|
BUBBLEWRAP_DEPENDENCIES = host-pkgconf libcap
|
|
|
|
BUBBLEWRAP_LICENSE = LGPL-2.0+
|
|
BUBBLEWRAP_LICENSE_FILES = COPYING
|
|
|
|
BUBBLEWRAP_CONF_OPTS = \
|
|
--enable-require-userns=no \
|
|
--disable-man \
|
|
--disable-sudo \
|
|
--with-priv-mode=none
|
|
|
|
ifeq ($(BR2_PACKAGE_BASH_COMPLETION),y)
|
|
BUBBLEWRAP_CONF_OPTS += --with-bash-completion-dir=/usr/share/bash-completion/completions
|
|
else
|
|
BUBBLEWRAP_CONF_OPTS += --without-bash-completion-dir
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBSELINUX),y)
|
|
BUBBLEWRAP_CONF_OPTS += --enable-selinux
|
|
BUBBLEWRAP_DEPENDENCIES += libselinux
|
|
else
|
|
BUBBLEWRAP_CONF_OPTS += --disable-selinux
|
|
endif
|
|
|
|
# We need to mark bwrap as setuid, in case the kernel
|
|
# has user namespaces disabled for non-root users.
|
|
define BUBBLEWRAP_PERMISSIONS
|
|
/usr/bin/bwrap f 1755 0 0 - - - - -
|
|
endef
|
|
|
|
$(eval $(autotools-package))
|