bug#47229: Local privilege escalation via guix-daemon and ‘--keep-failed’

2021-04-10 Thread Leo Famulari
On Thu, Mar 18, 2021 at 12:17:15PM +0100, Ludovic Courtès wrote: > Vulnerability > ~ > > The attack consists in having an unprivileged user spawn a build > process, for instance with ‘guix build’, that makes its build directory > world-writable. The user then creates a hardlink within

bug#47229: Local privilege escalation via guix-daemon and ‘--keep-failed’

2021-03-18 Thread Leo Famulari
On Thu, Mar 18, 2021 at 12:17:15PM +0100, Ludovic Courtès wrote: > It does not affect multi-user setups where ‘guix-daemon’ runs on a > separate machine and is accessed over the network, via > ‘GUIX_DAEMON_SOCKET’, as is customary on cluster setups. Machines where > the Linux “protected hardlink”[

bug#47229: Local privilege escalation via guix-daemon and ‘--keep-failed’

2021-03-18 Thread Ludovic Courtès
An additional data point: guix-daemon chowns build trees to the caller upon failure (a very handy feature) since this 2016 commit: https://git.savannah.gnu.org/cgit/guix.git/commit/?id=2608e40988ba8cf51723fe0d21bdedf6b3997c9c The Nix build daemon, which guix-daemon is based on, did not have th

bug#47229: Local privilege escalation via guix-daemon and ‘--keep-failed’

2021-03-18 Thread Léo Le Bouter via Bug reports for GNU Guix
Thanks a lot to the reporter and for working on this! signature.asc Description: This is a digitally signed message part

bug#47229: Local privilege escalation via guix-daemon and ‘--keep-failed’

2021-03-18 Thread Ludovic Courtès
Ludovic Courtès skribis: > The fix (patch attached) consists in adding a root-owned “wrapper” > directory in which the build directory itself is located. The fix has now been pushed: https://git.savannah.gnu.org/cgit/guix.git/commit/?id=ec7fb669945bfb47c5e1fdf7de3a5d07f7002ccf Followed by a

bug#47229: Local privilege escalation via guix-daemon and ‘--keep-failed’

2021-03-18 Thread Ludovic Courtès
A security vulnerability that can lead to local privilege escalation has been found in ’guix-daemon’. It affects multi-user setups in which ’guix-daemon’ runs locally. It does not affect multi-user setups where ‘guix-daemon’ runs on a separate machine and is accessed over the network, via ‘GUIX_D