REF:https://bugzilla.tianocore.org/show_bug.cgi?id=1279
According to the ECMA-167 standard (3rd Edition - June 1997), Section
14.16.1.1, valid values are 1 to 5. All other values will be treated as a
corrupted volume.
This commit will add such check within function ResolveSymlink().
Cc: Ruiyu Ni <ruiyu.ni@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>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
}\r
FileName[Index] = L'\0';\r
break;\r
+ default:\r
+ //\r
+ // According to the ECMA-167 standard (3rd Edition - June 1997), Section\r
+ // 14.16.1.1, all other values are reserved.\r
+ //\r
+ Status = EFI_VOLUME_CORRUPTED;\r
+ goto Error_Find_File;\r
}\r
\r
//\r