Hopefully final tweak for XXE to prevent displaying errors if SimpleXML isn't available

This commit is contained in:
Mark Baker 2014-02-21 10:28:17 +00:00
parent 2f4fd4cdcb
commit 6c8884b2eb
1 changed files with 1 additions and 1 deletions

View File

@ -378,10 +378,10 @@ class PHPExcel_Settings
*/
public static function getLibXmlLoaderOptions()
{
libxml_disable_entity_loader(true);
if (is_null(self::$_libXmlLoaderOptions)) {
self::setLibXmlLoaderOptions(LIBXML_DTDLOAD | LIBXML_DTDATTR);
}
@libxml_disable_entity_loader($options == (LIBXML_DTDLOAD | LIBXML_DTDATTR));
return self::$_libXmlLoaderOptions;
} // function getLibXmlLoaderOptions
}