Received: from list by lists.gnu.org with archive (Exim 4.71) id 1gCq9a-0005QM-Vt for mharc-grub-devel@gnu.org; Wed, 17 Oct 2018 14:02:43 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40561) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gCq9Y-0005QA-Ve for grub-devel@gnu.org; Wed, 17 Oct 2018 14:02:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gCq9U-0001yT-VK for grub-devel@gnu.org; Wed, 17 Oct 2018 14:02:40 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:36067) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gCq9U-0001p2-8C for grub-devel@gnu.org; Wed, 17 Oct 2018 14:02:36 -0400 Received: by mail-wr1-x443.google.com with SMTP id y16so30737276wrw.3 for ; Wed, 17 Oct 2018 11:02:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cloudflare.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=/shi0+Sm1k4HL7zrUgz3zxaArWaJZb4wksvQrNRmJnI=; b=mISFPwhR7MrJSqS5ep89ZE+qhZj6OBYxd1fjqfgU8x2oaKflZMYsjoe8p5OqGx58RI SOEp7rg3twkANGL+tyRwIQhwo7ASf/UDpT8TRMPvH5VzMRxFyTM4+KCR0khNuj7pSk1L qudUW16Mr8+oFRROWR30czCg9ve86GicQhzrs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=/shi0+Sm1k4HL7zrUgz3zxaArWaJZb4wksvQrNRmJnI=; b=E7P0CNTLOc6TJt/g5KY8dkSw3hRYJ8XbPA52U+6gzK10DiHsZ4BE+h1UyQRGIlmS7Z SCg6hlT1e8du8FmnJ3NCHYZHw2GSY3E5PrDYZY6fltgb+AJFamPrazWsmrONJC63odOh DuKrjhy7iU/PuD8ZwnvaUhPYFxrLcahoFRggJrk3xtePgPWuVsqAndvbNw6nbFzz3zcb zXQfjeupJlebcN8dXJqCLYk4QynQ/o0efdCosZOqb4qu+LNkmuT7ZFQBWki9QfEVyF3S YMjA/mISAWIypM2zYWdt8lWXR0WxSwZya2aNNcVW6eSa64/uBG6Htygia7Mn8dgSKWqI 4KLg== X-Gm-Message-State: ABuFfogp9MyFdK2VUV7G9YLBEAFT1o8IKPpzvKvOQTr8fXRjFk9uav9A eQKOTir4Qn78CflGs5vKrQq/6ycsy6gqkQ== X-Google-Smtp-Source: ACcGV63QCK2cC+EeY1VilMLcxxlT0ebUJxUpPST5D1MS1wIRcfY0iK1A0lx3LHBNo5dmSrCro8YMBg== X-Received: by 2002:a5d:484e:: with SMTP id n14-v6mr24307466wrs.234.1539799351177; Wed, 17 Oct 2018 11:02:31 -0700 (PDT) Received: from localhost.localdomain ([185.122.0.240]) by smtp.gmail.com with ESMTPSA id c21-v6sm3229864wmh.26.2018.10.17.11.02.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Oct 2018 11:02:30 -0700 (PDT) From: Ignat Korchagin To: grub-devel@gnu.org Cc: Ignat Korchagin Subject: [PATCH v2 0/2] report UEFI secure boot status to the Linux kernel Date: Wed, 17 Oct 2018 18:01:44 +0000 Message-Id: <20181017180146.18299-1-ignat@cloudflare.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20181017145905.GE25306@router-fw-old.i.net-space.pl> References: <20181017145905.GE25306@router-fw-old.i.net-space.pl> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::443 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Oct 2018 18:02:41 -0000 Reworked the logic to more closely resemble the one in the Linux efistub implementation: * added checking for "MokSBState" variable * added a function to efi core to read EFI variables with their attributes, because "MokSBState" handling requires taking attributes into account Ignat Korchagin (2): efi: add function to read EFI variables with attributes loader/i386/linux: report UEFI secure boot status to the Linux kernel grub-core/kern/efi/efi.c | 13 +++++++++-- grub-core/loader/i386/linux.c | 54 ++++++++++++++++++++++++++++++++++++++++++- include/grub/efi/efi.h | 4 ++++ include/grub/i386/linux.h | 14 +++++++++-- 4 files changed, 80 insertions(+), 5 deletions(-) -- 2.11.0