MdeModulePkg/UdfDxe: Add boundary check for getting volume (free) size
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=828 Within GetVolumeSize(): The boundary check will validate the 'NumberOfPartitions' field of a Logical Volume Integrity Descriptor matches the data within the relating Logical Volume Descriptor. Cc: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Paulo Alcantara <palcantara@suse.de> Acked-by: Star Zeng <star.zeng@intel.com>
This commit is contained in:
@@ -903,6 +903,13 @@ SetFileInfo (
|
||||
/**
|
||||
Get volume and free space size information of an UDF volume.
|
||||
|
||||
@attention This is boundary function that may receive untrusted input.
|
||||
@attention The input is from FileSystem.
|
||||
|
||||
The Logical Volume Descriptor and the Logical Volume Integrity Descriptor are
|
||||
external inputs, so this routine will do basic validation for both descriptors
|
||||
and report status.
|
||||
|
||||
@param[in] BlockIo BlockIo interface.
|
||||
@param[in] DiskIo DiskIo interface.
|
||||
@param[in] Volume UDF volume information structure.
|
||||
|
Reference in New Issue
Block a user