Go to file
Jagadeesh Krishnanjanappa 9833879d81 shadow: CVE-2018-7169
newgidmap: enforce setgroups=deny if self-mapping a group

This is necessary to match the kernel-side policy of "self-mapping in a
user namespace is fine, but you cannot drop groups" -- a policy that was
created in order to stop user namespaces from allowing trivial privilege
escalation by dropping supplementary groups that were "blacklisted" from
certain paths.

This is the simplest fix for the underlying issue, and effectively makes
it so that unless a user has a valid mapping set in /etc/subgid (which
only administrators can modify) -- and they are currently trying to use
that mapping -- then /proc/$pid/setgroups will be set to deny. This
workaround is only partial, because ideally it should be possible to set
an "allow_setgroups" or "deny_setgroups" flag in /etc/subgid to allow
administrators to further restrict newgidmap(1).

We also don't write anything in the "allow" case because "allow" is the
default, and users may have already written "deny" even if they
technically are allowed to use setgroups. And we don't write anything if
the setgroups policy is already "deny".

Ref: https://bugs.launchpad.net/ubuntu/+source/shadow/+bug/1729357
Fixes: CVE-2018-7169

Affects shadow <= 4.5

(From OE-Core rev: a875522540372a4fa6658885692e564dfd729f54)

(From OE-Core rev: cfc8931d53cf9959995a4068a7e397e100922358)

Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-10-10 13:27:02 +01:00
bitbake bitbake: checksum: sanity check path when recursively checksumming 2018-08-29 15:23:58 +01:00
documentation documentation: Preparation for 2.4.4 release 2018-08-15 10:28:18 +01:00
meta shadow: CVE-2018-7169 2018-10-10 13:27:02 +01:00
meta-poky poky: Bump version to 2.4.3 2018-05-23 17:46:21 +01:00
meta-selftest meta-selftest: fix upstream version checks for devtool test recipes 2018-01-06 10:13:55 +00:00
meta-skeleton meta*: Add LAYERSERIES_COMPAT and LAYERSERIES_CORENAMES markup to layer.conf 2017-06-12 15:08:30 +01:00
meta-yocto-bsp oeqa/selftest/systemd_boot: Never use cleansstate in QA tests without special handling of SSTATE_DIR 2018-07-15 16:19:15 +01:00
scripts multilib_header: recognize BPF as a target 2018-09-13 10:55:38 +01:00
.gitignore add !meta-poky to .gitignore file 2016-03-26 08:06:58 +00:00
.templateconf meta-yocto: Rename to meta-poky to better match its purpose 2016-02-28 11:31:17 +00:00
LICENSE
oe-init-build-env oe-init-build-env-memres: Drop it 2017-07-21 08:44:25 +01:00
README.hardware meta-yocto: Restructure and tidy up READMEs 2017-09-14 13:36:22 +01:00
README.LSB README.LSB: describe oe-core's deviations from the LSB spec 2017-06-28 15:52:17 +01:00
README.poky meta-yocto: Restructure and tidy up READMEs 2017-09-14 13:36:22 +01:00
README.qemu README.qemu: qemuppc64 is not supported 2017-10-16 23:54:31 +01:00

QEMU Emulation Targets
======================

To simplify development, the build system supports building images to
work with the QEMU emulator in system emulation mode. Several architectures
are currently supported in 32 and 64 bit variants:

  * ARM (qemuarm + qemuarm64)
  * x86 (qemux86 + qemux86-64)
  * PowerPC (qemuppc only)
  * MIPS (qemumips + qemumips64)

Use of the QEMU images is covered in the Yocto Project Reference Manual.
The appropriate MACHINE variable value corresponding to the target is given
in brackets.