[packages/tinyxml] Rel 11. Fix CVE-2023-34194 and CVE-2021-42260 with Debian patches.
arekm
arekm at pld-linux.org
Thu Nov 26 08:26:54 CET 2026
commit 3d852070a3be84dda2e1f4cae63378701f40d325
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Thu Nov 26 03:32:29 2026 +0100
Rel 11. Fix CVE-2023-34194 and CVE-2021-42260 with Debian patches.
Fixes CVE-2023-34194, CVE-2021-42260.
CVE-2021-42260.patch | 17 +++++++++++++++++
CVE-2023-34194.patch | 17 +++++++++++++++++
tinyxml.spec | 6 +++++-
3 files changed, 39 insertions(+), 1 deletion(-)
---
diff --git a/tinyxml.spec b/tinyxml.spec
index 46d2997..3a83ca3 100644
--- a/tinyxml.spec
+++ b/tinyxml.spec
@@ -3,7 +3,7 @@ Summary: A simple, small, C++ XML parser
Summary(pl.UTF-8): Prosty, mały, napisany w C++ parser XML
Name: tinyxml
Version: 2.6.2
-Release: 10
+Release: 11
License: Zlib
Group: Libraries
Source0: https://downloads.sourceforge.net/tinyxml/%{name}_%{file_version}.tar.gz
@@ -11,6 +11,8 @@ Source0: https://downloads.sourceforge.net/tinyxml/%{name}_%{file_version}.tar.g
Source1: %{name}.pc.in
Patch0: %{name}-flags.patch
Patch1: enforce-use-stl.patch
+Patch2: CVE-2021-42260.patch
+Patch3: CVE-2023-34194.patch
# dead
#URL: http://www.grinninglizard.com/tinyxml/
URL: https://sourceforge.net/projects/tinyxml/
@@ -55,6 +57,8 @@ Statyczna biblioteka tinyxml.
%setup -q -n %{name}
%patch -P0 -p1
%patch -P1 -p1
+%patch -P2 -p1
+%patch -P3 -p1
%build
%{__make} \
diff --git a/CVE-2021-42260.patch b/CVE-2021-42260.patch
new file mode 100644
index 0000000..d1d964b
--- /dev/null
+++ b/CVE-2021-42260.patch
@@ -0,0 +1,17 @@
+# CVE-2021-42260: infinite loop in TiXmlParsingData::Stamp on malformed UTF-8 lead byte
+# https://sourceforge.net/p/tinyxml/git/merge-requests/1/
+--- a/tinyxmlparser.cpp
++++ b/tinyxmlparser.cpp
+@@ -274,6 +274,12 @@ void TiXmlParsingData::Stamp( const char* now, TiXmlEncoding encoding )
+ else
+ { p +=3; ++col; } // A normal character.
+ }
++ else
++ {
++ // TIXML_UTF_LEAD_0 (239) is the start character of a 3 byte sequence, so
++ // there is something wrong here. Just advance the pointer to evade infinite loops
++ ++p;
++ }
+ }
+ else
+ {
diff --git a/CVE-2023-34194.patch b/CVE-2023-34194.patch
new file mode 100644
index 0000000..57281a5
--- /dev/null
+++ b/CVE-2023-34194.patch
@@ -0,0 +1,17 @@
+# CVE-2023-34194: reachable assertion via NUL after whitespace in a declaration
+# https://bugs.debian.org/1059315
+diff --git a/tinyxmlparser.cpp b/tinyxmlparser.cpp
+index 8aa0dfa..1601962 100644
+--- a/tinyxmlparser.cpp
++++ b/tinyxmlparser.cpp
+@@ -1606,6 +1606,10 @@ const char* TiXmlDeclaration::Parse( const char* p, TiXmlParsingData* data, TiXm
+ }
+
+ p = SkipWhiteSpace( p, _encoding );
++ if ( !p || !*p )
++ {
++ break;
++ }
+ if ( StringEqual( p, "version", true, _encoding ) )
+ {
+ TiXmlAttribute attrib;
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/tinyxml.git/commitdiff/3d852070a3be84dda2e1f4cae63378701f40d325
More information about the pld-cvs-commit
mailing list