2 ms·
Most XML libraries have an option to disable external entity loading. But this is not enough. Libraries should be secure by default, not by toggling an obscure
by kijin 12y ago
Most XML libraries have an option to disable external entity loading. But this is not enough. Libraries should be secure by default, not by toggling an obscure option. (On a related note, why do we still have so many templating engines that don't block XSS by default?)
Recent versions of libxml (2.9.0+) disable external entity loading by default, so any implementation based on libxml (such as PHP's SimpleXML) should be secure as long as the defaults are left untouched. But if you use an XML parser implemented natively in another language, or one that links to an older version of libxml, you should look really carefully at the default settings.
- bazzargh 12y agominor correction - 2.9.2+. (2.9.0, 2.9.1 had buggy attempts to disable entity expansion, and were still exploitable) - http://www.cvedetails.com/cve/CVE-2014-3660/ http://www.cvedetails.com/cve/CVE-2014-3660/