Disallow deep or widely nested entity references.
authorMitch Curtis <mitch.curtis@digia.com>
Thu, 7 Nov 2013 08:36:29 +0000 (09:36 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Thu, 7 Nov 2013 12:56:40 +0000 (13:56 +0100)
commit512a1ce0698d370c313bb561bbf078935fa0342e
tree4cbb038859c99aa81c99678c52f6a76de7aa615b
parentcab363afa347e22c5f738f15533489e0cd671d59
Disallow deep or widely nested entity references.

Nested references with a depth of 2 or greater will fail. References
that partially expand to greater than 1024 characters will also fail.

This is a backport of 46a8885ae486e238a39efa5119c2714f328b08e4.

Change-Id: I0c2e1fa13d6ccb5f88641dae2ed3f28bfdeaf609
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
src/xml/sax/qxml.cpp
tests/auto/qxmlsimplereader/tst_qxmlsimplereader.cpp
tests/auto/qxmlsimplereader/xmldocs/1-levels-nested-dtd.xml [new file with mode: 0644]
tests/auto/qxmlsimplereader/xmldocs/2-levels-nested-dtd.xml [new file with mode: 0644]
tests/auto/qxmlsimplereader/xmldocs/internal-entity-polynomial-attribute.xml [new file with mode: 0644]