summaryrefslogtreecommitdiff
path: root/test/errors
diff options
context:
space:
mode:
authorNick Wellnhofer <wellnhofer@aevum.de>2017-07-25 14:59:49 +0200
committerNick Wellnhofer <wellnhofer@aevum.de>2017-07-25 15:21:12 +0200
commit899a5d9f0ed13b8e32449a08a361e0de127dd961 (patch)
tree62c448c573d21f4d49c0b1a9def7e70cf4cd9d98 /test/errors
parentfb56f80eeffde4b79a49667c3f0727181d57aeb3 (diff)
downloadlibxml2-899a5d9f0ed13b8e32449a08a361e0de127dd961.tar.gz
Detect infinite recursion in parameter entities
When expanding a parameter entity in a DTD, infinite recursion could lead to an infinite loop or memory exhaustion. Thanks to Wei Lei for the first of many reports. Fixes bug 759579.
Diffstat (limited to 'test/errors')
-rw-r--r--test/errors/759579.xml11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/errors/759579.xml b/test/errors/759579.xml
new file mode 100644
index 00000000..7fadd702
--- /dev/null
+++ b/test/errors/759579.xml
@@ -0,0 +1,11 @@
+<!DOCTYPE doc [
+ <!ENTITY % z '
+ &#37;z; &#37;z; &#37;z; &#37;z; &#37;z;
+ &#37;z; &#37;z; &#37;z; &#37;z; &#37;z;
+ &#37;z; &#37;z; &#37;z; &#37;z; &#37;z;
+ &#37;z; &#37;z; &#37;z; &#37;z; &#37;z;
+ &#37;z; &#37;z; &#37;z; &#37;z; &#37;z;
+ '>
+ %z;
+]>
+<doc/>