mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 07:28:39 +01:00
libxml2: add Debian patches to address CVEs
Debian uses libxml2 2.9.4 in Stretch. This adds their security related fixes from 2.9.4+dfsg1-2.2+deb9u2 to LEDE's 17.01 release. Fixed CVEs: CVE-2016-4658 CVE-2016-5131 CVE-2017-0663 CVE-2017-15412 CVE-2017-7375 CVE-2017-7376 CVE-2017-9047 CVE-2017-9048 CVE-2017-9049 CVE-2017-9050 Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
This commit is contained in:
@@ -0,0 +1,50 @@
|
||||
From e905f08123e4a6e7731549e6f09dadff4cab65bd Mon Sep 17 00:00:00 2001
|
||||
From: Nick Wellnhofer <wellnhofer@aevum.de>
|
||||
Date: Sun, 26 Jun 2016 12:38:28 +0200
|
||||
Subject: [PATCH] Fix more NULL pointer derefs in xpointer.c
|
||||
|
||||
Found with afl-fuzz.
|
||||
---
|
||||
xpointer.c | 12 +++++++-----
|
||||
1 file changed, 7 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/xpointer.c b/xpointer.c
|
||||
index 694d120..e643ee9 100644
|
||||
--- a/xpointer.c
|
||||
+++ b/xpointer.c
|
||||
@@ -542,7 +542,7 @@ xmlXPtrNewRangeNodeObject(xmlNodePtr start, xmlXPathObjectPtr end) {
|
||||
/*
|
||||
* Empty set ...
|
||||
*/
|
||||
- if (end->nodesetval->nodeNr <= 0)
|
||||
+ if ((end->nodesetval == NULL) || (end->nodesetval->nodeNr <= 0))
|
||||
return(NULL);
|
||||
endNode = end->nodesetval->nodeTab[end->nodesetval->nodeNr - 1];
|
||||
endIndex = -1;
|
||||
@@ -1361,7 +1361,7 @@ xmlXPtrEval(const xmlChar *str, xmlXPathContextPtr ctx) {
|
||||
*/
|
||||
xmlNodeSetPtr set;
|
||||
set = tmp->nodesetval;
|
||||
- if ((set->nodeNr != 1) ||
|
||||
+ if ((set == NULL) || (set->nodeNr != 1) ||
|
||||
(set->nodeTab[0] != (xmlNodePtr) ctx->doc))
|
||||
stack++;
|
||||
} else
|
||||
@@ -2034,9 +2034,11 @@ xmlXPtrRangeFunction(xmlXPathParserContextPtr ctxt, int nargs) {
|
||||
xmlXPathFreeObject(set);
|
||||
XP_ERROR(XPATH_MEMORY_ERROR);
|
||||
}
|
||||
- for (i = 0;i < oldset->locNr;i++) {
|
||||
- xmlXPtrLocationSetAdd(newset,
|
||||
- xmlXPtrCoveringRange(ctxt, oldset->locTab[i]));
|
||||
+ if (oldset != NULL) {
|
||||
+ for (i = 0;i < oldset->locNr;i++) {
|
||||
+ xmlXPtrLocationSetAdd(newset,
|
||||
+ xmlXPtrCoveringRange(ctxt, oldset->locTab[i]));
|
||||
+ }
|
||||
}
|
||||
|
||||
/*
|
||||
--
|
||||
2.1.4
|
||||
|
||||
Reference in New Issue
Block a user