From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id MB0BJZBXDmHZtwAAgWs5BA (envelope-from ) for ; Sat, 07 Aug 2021 11:51:12 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id iGy9IJBXDmGraAAAbx9fmQ (envelope-from ) for ; Sat, 07 Aug 2021 09:51:12 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 7F926166C6 for ; Sat, 7 Aug 2021 11:51:11 +0200 (CEST) Received: from localhost ([::1]:35230 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mCIz0-0000um-CW for larch@yhetil.org; Sat, 07 Aug 2021 05:51:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33006) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mCIys-0000ud-Ph for guix-patches@gnu.org; Sat, 07 Aug 2021 05:51:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40421) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mCIys-0005v0-JM for guix-patches@gnu.org; Sat, 07 Aug 2021 05:51:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mCIys-0007YN-EM for guix-patches@gnu.org; Sat, 07 Aug 2021 05:51:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49898] [PATCH v2] gnu: Add spectre-meltdown-checker. Resent-From: Leo Prikler Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 07 Aug 2021 09:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49898 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: phodina , 49898@debbugs.gnu.org Received: via spool by 49898-submit@debbugs.gnu.org id=B49898.162832981528974 (code B ref 49898); Sat, 07 Aug 2021 09:51:02 +0000 Received: (at 49898) by debbugs.gnu.org; 7 Aug 2021 09:50:15 +0000 Received: from localhost ([127.0.0.1]:51967 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCIy2-0007X6-0M for submit@debbugs.gnu.org; Sat, 07 Aug 2021 05:50:15 -0400 Received: from mailrelay.tugraz.at ([129.27.2.202]:50866) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCIxy-0007Wp-R5 for 49898@debbugs.gnu.org; Sat, 07 Aug 2021 05:50:08 -0400 Received: from nijino.local (194-118-35-216.adsl.highway.telekom.at [194.118.35.216]) by mailrelay.tugraz.at (Postfix) with ESMTPSA id 4Ghcyg0mRwz1LBCr; Sat, 7 Aug 2021 11:50:02 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 mailrelay.tugraz.at 4Ghcyg0mRwz1LBCr DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tugraz.at; s=mailrelay; t=1628329803; bh=MnGfLfS5jo34/D2QgOfhTZH50GjOw4AYYJy2u1pwdck=; h=Subject:From:To:Date:In-Reply-To:References:From; b=BuCeB74wqcbMyU4/sg/ekZAfGRDnOUDrwX/SE+kK+rxoaZ+xWNIOp6YxusGRH7S0y NONRWPx20clEmiid/tavKNu5RFlt7xIoCPocsxzkObwZeYAss/YIAJQu6sTie9BUaI GJe6m2/AREb0g2GyKkmnSqBSMEc6Pcv1BDCZAUgc= Message-ID: <9500dbad2e885d13d06e3301f27261823d6f8698.camel@student.tugraz.at> From: Leo Prikler Date: Sat, 07 Aug 2021 11:50:02 +0200 In-Reply-To: <3xoFvRtUq0ydTy_fT8l5k0jlZhvtRTdSW107c9FiBmSCvQtXUapBOqbJkTEYJtGQrlcc9RcmOSdvqayP_lMcYc71m4squo4DReV_zFEt-00=@protonmail.com> References: <3xoFvRtUq0ydTy_fT8l5k0jlZhvtRTdSW107c9FiBmSCvQtXUapBOqbJkTEYJtGQrlcc9RcmOSdvqayP_lMcYc71m4squo4DReV_zFEt-00=@protonmail.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.34.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-TUG-Backscatter-control: bt4lQm5Tva3SBgCuw0EnZw X-Spam-Scanner: SpamAssassin 3.003001 X-Spam-Score-relay: -1.9 X-Scanned-By: MIMEDefang 2.74 on 129.27.10.117 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1628329872; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=MnGfLfS5jo34/D2QgOfhTZH50GjOw4AYYJy2u1pwdck=; b=dLP8wq3C1ZZ/m+4ApQnRaz/iSIw3NFIEspgPyZI0j8AGMpkiGPfZ0JlcD4Po0fLCaAF1oa 7Ue+Qye3lyMb4vLPMZuP3tBDFRlhNRIJ5A4GmwkGwqa7/zq5EYna6metwcB6VNP9hDMkXd 20MC8NRFGJgbp7GPKlvm4t5s8G2o0AltW1a+HISwCz68T4fCSrU618cryhvplD2iGUgfdf uTDWuG/283mr7pJ/MmXL77AHoFcIZFG4FqiFlLlgZamy2CWy5mp5NzMJcqTS0a3wQitik1 yXNG7C7t54Ab7KN15a6iEgfAgzJf2lkukcyAG1wWaHHhML0KtBBlUxwofnESBQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1628329872; a=rsa-sha256; cv=none; b=jfGuBBQM36T1Bn3fZUdAIR07dWWjDxStrzYfIFXzTLMu1rxSBK4rfWWudYHKpAaNmHlxhJ WLJCgW0P8QuqAkFiaURDRG09sa02sVkcbRVUDnOD7y1FaHDMiInPVuqh/nxINoiKqodcAF 52MBtJP3LkPLTBtxG6V75aTQ3gmyLfT1ZKgvTh/N7t4NXxldr0NJIbhZRcm8nP3gqGo0oW yOqxAy0WTkt8ONMplhTW9AoktaVwyIwntZBZFkkX9b4KuIPXFXCAgmHiZ+zWTQhyCITiDF eB6ssdyoyoSZmCboFTq8EZ4KYNsvMioYLyIVYVkc6vIUG6GzunwoBwFY+e6lTg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tugraz.at header.s=mailrelay header.b=BuCeB74w; dmarc=fail reason="SPF not aligned (relaxed)" header.from=student.tugraz.at (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -1.32 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tugraz.at header.s=mailrelay header.b=BuCeB74w; dmarc=fail reason="SPF not aligned (relaxed)" header.from=student.tugraz.at (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 7F926166C6 X-Spam-Score: -1.32 X-Migadu-Scanner: scn0.migadu.com X-TUID: mxXRNPEkAQqv Hi, Am Samstag, den 07.08.2021, 09:04 +0000 schrieb phodina: > Thanks Leo for the suggestions! > ------------------- > * gnu/packages/linux.scm (spectre-meltdown-checker): New variable. > > diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm > index 4ca2a386e1..3529fa02e2 100644 > --- a/gnu/packages/linux.scm > +++ b/gnu/packages/linux.scm > @@ -53,6 +53,7 @@ > ;;; Copyright © 2020 pukkamustard > ;;; Copyright © 2021 B. Wilson > ;;; Copyright © 2021 Ivan Gankevich > +;;; Copyright © 2021 Petr Hodina > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -148,6 +149,7 @@ > #:use-module (guix build-system cmake) > #:use-module (guix build-system gnu) > #:use-module (guix build-system go) > + #:use-module (guix build-system copy) > #:use-module (guix build-system meson) > #:use-module (guix build-system python) > #:use-module (guix build-system trivial) > @@ -7191,6 +7193,32 @@ interfaces in parallel environments.") > (supported-systems '("i686-linux" "x86_64-linux")) > (license (list license:bsd-2 license:gpl2)))) ;dual > > +(define-public spectre-meltdown-checker > +(package > + (name "spectre-meltdown-checker") > + (version "0.44") > + (source (origin > + (method git-fetch) > + (uri (git-reference > + (url " > https://github.com/speed47/spectre-meltdown-checker") > + (commit (string-append "v" version)))) > + (file-name (git-file-name name version)) > + (sha256 > + (base32 > + "1b47wlc52jnp2d5c7kbqnxmlm4g3cfbv25q30llv5mlmzs6d7bam" > )))) > + (build-system copy-build-system) > + (arguments > + `(#:install-plan '(("spectre-meltdown-checker.sh" > + "bin/spectre-meltdown-checker.sh")))) > + (inputs `(("util-linux" ,util-linux) > + ("binutils" ,binutils))) We typically sort inputs alphabetically. > + (synopsis "Spectre, Meltdown ... vulnerability/mitigation > checker") > + (description "A shell script to assess your system's resilience > against > +the several transient execution CVEs that were published since early > 2018, > +and give you guidance as to how to mitigate them.") > + (home-page "https://github.com/speed47/spectre-meltdown-checker") > + (license license:gpl3))) This looks better, but after running the checker in a few configurations (it doesn't appear to make a difference whether with or without root, but judging from the papers some attacks would require sudo) I've noticed that commands are insufficiently hardcoded. For instance, the check for Spectre Variant 1 requires perl, which is not available and the line stating so is hidden well among a large wall of output. Likewise, I don't think simply including binutils does anything, you'll have to patch those in as well if you want them. Regards,