Re: [edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-03-17 Thread Ard Biesheuvel
On 17 March 2017 at 12:35, Laszlo Ersek wrote: > On 03/17/17 13:11, Ard Biesheuvel wrote: >> On 17 March 2017 at 12:07, Laszlo Ersek wrote: >>> On 02/26/17 15:00, Ard Biesheuvel wrote: On 25 February 2017 at 04:04, Yao, Jiewen

Re: [edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-03-17 Thread Laszlo Ersek
On 03/17/17 13:11, Ard Biesheuvel wrote: > On 17 March 2017 at 12:07, Laszlo Ersek wrote: >> On 02/26/17 15:00, Ard Biesheuvel wrote: >>> On 25 February 2017 at 04:04, Yao, Jiewen wrote: Hi Ard I agree with you on this enhancement. I

Re: [edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-03-17 Thread Ard Biesheuvel
On 17 March 2017 at 12:07, Laszlo Ersek wrote: > On 02/26/17 15:00, Ard Biesheuvel wrote: >> On 25 February 2017 at 04:04, Yao, Jiewen wrote: >>> Hi Ard >>> I agree with you on this enhancement. >>> >>> I prefer to adding the description as comment in the

Re: [edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-03-17 Thread Laszlo Ersek
On 02/26/17 15:00, Ard Biesheuvel wrote: > On 25 February 2017 at 04:04, Yao, Jiewen wrote: >> Hi Ard >> I agree with you on this enhancement. >> >> I prefer to adding the description as comment in the code, so that people >> can get clear picture when he/she reads the code.

Re: [edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-02-26 Thread Ard Biesheuvel
On 25 February 2017 at 04:04, Yao, Jiewen wrote: > Hi Ard > I agree with you on this enhancement. > > I prefer to adding the description as comment in the code, so that people > can get clear picture when he/she reads the code. > > // > // Instead of assuming that a PE/COFF

Re: [edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-02-24 Thread Yao, Jiewen
Hi Ard I agree with you on this enhancement. I prefer to adding the description as comment in the code, so that people can get clear picture when he/she reads the code. // // Instead of assuming that a PE/COFF section of type EFI_IMAGE_SCN_CNT_CODE // can always be mapped read-only, classify a

[edk2] [PATCH] MdeModulePkg/DxeCore: base code protection on permission attributes

2017-02-24 Thread Ard Biesheuvel
Instead of assuming that a PE/COFF section of type EFI_IMAGE_SCN_CNT_CODE can always be mapped read-only, classify a section as a code section only if it has the executable attribute set and the writable attribute cleared. This adheres more closely to the PE/COFF spec, and avoids issues with