GNU bug report logs

#37744 Insecure permissions on /var/guix/profiles/per-user (CVE-2019-18192)

PackageSource(s)Maintainer(s)
guix PTS Buildd Popcon
Full log

Message #69 received at 37744@debbugs.gnu.org (full text, mbox, reply):

Received: (at 37744) by debbugs.gnu.org; 16 Oct 2019 19:58:53 +0000
From debbugs-submit-bounces@debbugs.gnu.org Wed Oct 16 15:58:53 2019
Received: from localhost ([127.0.0.1]:46606 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces@debbugs.gnu.org>)
	id 1iKpRd-0001V1-10
	for submit@debbugs.gnu.org; Wed, 16 Oct 2019 15:58:53 -0400
Received: from lepiller.eu ([89.234.186.109]:41580)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <julien@lepiller.eu>) id 1iKpRW-0001Uh-KX
 for 37744@debbugs.gnu.org; Wed, 16 Oct 2019 15:58:48 -0400
Received: from lepiller.eu (localhost [127.0.0.1])
 by lepiller.eu (OpenSMTPD) with ESMTP id 08337429;
 Wed, 16 Oct 2019 19:58:44 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=lepiller.eu; h=date:from
 :to:cc:subject:message-id:in-reply-to:references:mime-version
 :content-type:content-transfer-encoding; s=dkim; bh=yS8O6vGjnqYa
 cY8NoQyPLydjLC8=; b=Eae28kSM7xTAlWFqCI1N+7eslgBPPXbgL5k0AgrZm+2I
 aTHD1NRUAWtE0f4orJCTslOR6BaAililU3bX24KPi+gAV2DJ+GCN/4n33xL172ID
 vk6WeHGc16K4LWMxektUAApfglXUU7ftAzaJ1Ikw8SryAk1ZAU60IYiZY54hE57z
 EcSOZZHUtY1ZH6dDl6iGbWhNvASU7IOmXjeRhy882U+Hh28Hx2lg3HHL8UUqYpts
 ghCbqqc4ay/zdjKQWxmzwwf5EZxbRGN4vLlGZXk60M0LnslgLMgxu1gchX4CW7OQ
 drMge0KcdXX3COLs8cahKoFXY53PgTp+qGFIbyDnlw==
Received: by lepiller.eu (OpenSMTPD) with ESMTPSA id c6cf8ef8
 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO); 
 Wed, 16 Oct 2019 19:58:44 +0000 (UTC)
Date: Wed, 16 Oct 2019 21:58:39 +0200
From: Julien Lepiller <julien@lepiller.eu>
To: Ludovic Courtès <ludo@gnu.org>
Subject: Re: bug#37744: Per-user profile directory hijack (CVE-2019-17365
 for Nix)
Message-ID: <20191016215839.73c32b64@sybil.lepiller.eu>
In-Reply-To: <87ftjsk4d3.fsf@gnu.org>
References: <87o8yjsr8o.fsf@gnu.org> <87blujsqq0.fsf@gnu.org>
 <87y2xno85o.fsf@nckx> <87d0eyuqzd.fsf@gnu.org>
 <87mue2nkrj.fsf@nckx> <8736fttby6.fsf@gnu.org>
 <87tv89rnva.fsf@gnu.org> <878spksty3.fsf@gnu.org>
 <20191016142221.qys2y2cb4spmwscq@pelzflorian.localdomain>
 <87ftjsoh40.fsf@nckx>
 <20191016151922.5fanqbt6kiv4offx@pelzflorian.localdomain>
 <87eezcogtf.fsf@nckx> <87ftjsk4d3.fsf@gnu.org>
X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-unknown-linux-gnu)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 37744
Cc: 37744@debbugs.gnu.org
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request@debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit@debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request@debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request@debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org>
X-Spam-Score: -1.0 (-)
Le Wed, 16 Oct 2019 19:05:44 +0200,
Ludovic Courtès <ludo@gnu.org> a écrit :

> Hi!
> 
> Thanks for your feedback Tobias, Florian, and Julien!
> 
> Taking that into account, I propose this (I’ve also changed the title
> to make it hopefully clearer):
> 
> --8<---------------cut here---------------start------------->8---
>  (entry (commit "FIXME")
>         (title (en "Insecure @file{/var/guix/profiles/per-user}
> permissions")) (body
>          (en "The default user profile, @file{~/.guix-profile},
> points to @file{/var/guix/profiles/per-user/$USER}.  Until now,
> @file{/var/guix/profiles/per-user} was world-writable, allowing the
> @command{guix} command to create the @code{$USER} sub-directory.
> 
> On a multi-user system, this allowed a malicious user to create and
> populate that @code{$USER} sub-directory for another user that had
> not yet logged in. Since @code{/var/@dots{}/$USER} is in
> @code{$PATH}, the target user could end up running attacker-provided
> code.  See @uref{https://issues.guix.gnu.org/issue/37744} for more
> information.
> 
> This is now fixed by letting @command{guix-daemon} create these
> directories on behalf of users and removing the world-writable
> permissions on @code{per-user}.  On multi-user systems, we recommend
> updating the daemon now. To do that, run @code{sudo guix pull} if
> you're on a foreign distro, or run @code{guix pull && sudo guix
> system reconfigure @dots{}} on Guix System.  In both cases, make sure
> to restart the service afterwards, with @code{herd} or
> @code{systemctl}."))) --8<---------------cut
> here---------------end--------------->8---

pour le français (n'hésite pas à reprendre le texte si tu trouves à
redire :)) :

titre : Permissions laxistes pour @file{/var/guix/profiles/per-user}

corps : Le profil utilisateur par défaut, @file{~/.guix-profile},
pointe vers @file{/var/guix/profiles/per-user/$USER}.  Jusqu'à
maintenant, @file{/var/guix/profiles/per-user} était disponible en
écriture pour tout le monde, ce qui permettait à la commande
@command{guix} de créér le sous-répertoire @code{$USER}.

Sur un système multi-utilisateur, cela permet à un utilisateur
malveillant de créer et de remplir le sous-répertoire @code{USER} pour
n'importe quel utilisateur qui ne s'est jamais connecté.  Comme
@code{/var/@dots{}/$USER} fait partie de @code{$PATH}, l'utilisateur
ciblé pouvait exécuter des programmes fournis par l'attaquant.  Voir
@uref{https://issues.guix.gnu.org/issue/37744} pour plus de détails.

Cela est maintenant corrigé en laissant à @command{guix-daemon} le soin
de créer ces répertoire pour le compte des utilisateurs et en
supprimant les permissions en écriture pour tout le monde sur
@code{per-user}.  Nous te recommandons de mettre à jour le démon
immédiatement.  Pour cela, lance @code{sudo guix pull} si tu es sur
une distro externe ou @code{guix pull && sudo guix system reconfigure
@dots{}} sur le système Guix.  Dans tous les cas, assure-toi ensuite de
redémarrer le service avec @code{herd} ou @code{systemctl}.

> 
> If this is fine with you, I hereby request translation of this entry.
> :-)
> 
> I’ll commit the change within a few hours if there are no objections.
> 
> Ludo’.
> 
> 
> 





Send a report that this bug log contains spam.


debbugs.gnu.org maintainers <help-debbugs@gnu.org>. Last modified: Sun Dec 22 11:25:45 2024; Machine Name: wallace-server

GNU bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.