RE: [PATCH 2/2] selftests/sgx: Add SGX selftest augment_via_eaccept_long

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: Jarkko Sakkinen <jarkko@xxxxxxxxxx>
> Sent: Wednesday, August 17, 2022 7:39 AM
> To: Dhanraj, Vijay <vijay.dhanraj@xxxxxxxxx>
> Cc: Chatre, Reinette <reinette.chatre@xxxxxxxxx>; Dave Hansen
> <dave.hansen@xxxxxxxxxxxxxxx>; linux-sgx@xxxxxxxxxxxxxxx; Shuah Khan
> <shuah@xxxxxxxxxx>; open list:KERNEL SELFTEST FRAMEWORK <linux-
> kselftest@xxxxxxxxxxxxxxx>; open list <linux-kernel@xxxxxxxxxxxxxxx>
> Subject: Re: [PATCH 2/2] selftests/sgx: Add SGX selftest
> augment_via_eaccept_long
> 
> On Wed, Aug 17, 2022 at 01:27:38AM +0000, Dhanraj, Vijay wrote:
> > I think changing it to "int i" will cause a buffer overflow with
> > edmm_size being 8GB.
> 
> Hmm.. 'i' iterates segments. Amd I missing something?
> 
> BR, Jarkko

It is also used when iterating over pages to eaccept. This might cause an issue.

	for (i = 0; i < edmm_size; i += 4096) {
		eaccept_op.epc_addr = (uint64_t)(addr + i);

Regards, Vijay




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux