public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Yao, Jiewen" <jiewen.yao@intel.com>
To: "Wang, Jian J" <jian.j.wang@intel.com>
Cc: "edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Subject: Re: [PATCH 0/2] Enable page table write protection
Date: Wed, 29 Nov 2017 09:15:48 +0000	[thread overview]
Message-ID: <19004429-87DC-4620-8A78-4EF085D5AD9D@intel.com> (raw)
In-Reply-To: <20171129084640.20076-1-jian.j.wang@intel.com>

Thanks.

May I know if this is validated in uefi shell, that all page table is readonly?

I did not find the code to set new allocated split page to be readonly. Can you give me a hand on that?

thank you!
Yao, Jiewen


> 在 2017年11月29日,下午4:47,Jian J Wang <jian.j.wang@intel.com> 写道:
> 
> Write Protect feature (CR0.WP) is always enabled in driver UefiCpuPkg/CpuDxe.
> But the memory pages used for page table are not set as read-only in the driver
> DxeIplPeim, after the paging is setup. This might jeopardize the page table
> integrity if there's buffer overflow occured in other part of system.
> 
> This patch series will change this situation by clearing R/W bit in page attribute
> of the pages used as page table.
> 
> Validation works include booting Windows (10/server 2016) and Linux (Fedora/Ubuntu)
> on OVMF and Intel real platform.
> 
> Jian J Wang (2):
> UefiCpuPkg/CpuDxe: Check CR0.WP before changing page table
> MdeModulePkg/DxeIpl: Mark page table as read-only
> 
> MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c | 166 +++++++++++++++++++++++
> MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.h |  14 ++
> UefiCpuPkg/CpuDxe/CpuPageTable.c                 |  65 ++++++++-
> 3 files changed, 241 insertions(+), 4 deletions(-)
> 
> -- 
> 2.14.1.windows.1
> 
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel

  parent reply	other threads:[~2017-11-29  9:11 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-29  8:46 [PATCH 0/2] Enable page table write protection Jian J Wang
2017-11-29  8:46 ` [PATCH 1/2] UefiCpuPkg/CpuDxe: Check CR0.WP before changing page table Jian J Wang
2017-11-29  8:46 ` [PATCH 2/2] MdeModulePkg/DxeIpl: Mark page table as read-only Jian J Wang
2017-11-29  9:15 ` Yao, Jiewen [this message]
2017-11-29 10:24   ` [PATCH 0/2] Enable page table write protection Wang, Jian J
2017-11-29 10:56     ` Yao, Jiewen
2017-11-29 12:15       ` Wang, Jian J
2017-11-29 13:35         ` Yao, Jiewen
2017-11-30  0:44           ` Wang, Jian J
2017-11-30  0:51             ` Yao, Jiewen
2017-11-30  1:16               ` Wang, Jian J
2017-11-30  1:36                 ` Yao, Jiewen
2017-11-30  1:43                   ` Yao, Jiewen
2017-11-30  1:46                   ` Wang, Jian J
2017-11-30  1:59                     ` Yao, Jiewen
2017-11-30  2:02                       ` Wang, Jian J
2017-11-30  2:36                       ` Wang, Jian J
2017-11-30  1:37                 ` Andrew Fish
2017-11-30  1:52                   ` Wang, Jian J
2017-11-29 12:38 ` Laszlo Ersek
2017-11-29 12:46   ` Wang, Jian J

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=19004429-87DC-4620-8A78-4EF085D5AD9D@intel.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox