aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2019-08-13 08:10:23 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2019-08-13 08:10:23 +0000
commit3f7f1749c88d4b23d858b584d358fadd836429da (patch)
treee6f89dd5ab186e7607bf8280f54275c78baf1b9b
parent16014107922e488262f117572a75e75e616e9462 (diff)
downloadaports-3f7f1749c88d4b23d858b584d358fadd836429da.tar.gz
aports-3f7f1749c88d4b23d858b584d358fadd836429da.tar.bz2
aports-3f7f1749c88d4b23d858b584d358fadd836429da.tar.xz
main/pango: security fix (CVE-2019-1010238)
Fixes #10721
-rw-r--r--main/pango/APKBUILD10
-rw-r--r--main/pango/CVE-2019-1010238.patch34
2 files changed, 42 insertions, 2 deletions
diff --git a/main/pango/APKBUILD b/main/pango/APKBUILD
index 7955cfd005..0f981ac0b8 100644
--- a/main/pango/APKBUILD
+++ b/main/pango/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=pango
pkgver=1.42.4
-pkgrel=1
+pkgrel=2
pkgdesc="A library for layout and rendering of text"
url="https://www.pango.org/"
arch="all"
@@ -15,8 +15,13 @@ triggers="$pkgname.trigger=/usr/lib/pango/*/modules"
subpackages="$pkgname-dev $pkgname-doc $pkgname-tools"
source="https://download.gnome.org/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz
disable-test-layout.patch
+ CVE-2019-1010238.patch
"
+# secfixes:
+# 1.42.4-r2:
+# - CVE-2019-1010238
+
build() {
cd "$srcdir"/$pkgname-$pkgver
meson \
@@ -48,4 +53,5 @@ tools() {
}
sha512sums="993e97f647eba0c5ed90bcfcb8228bf67fa3f20b1f4331e4e40a30788d7c3ac55eee1209471bf21df125cb8fc6121acc8062a9da2f8a7d6cbe8e9ad13a9320dc pango-1.42.4.tar.xz
-e3d819bb29b3b6fc849a1e6b6413c21dd89386d54ddf44d6598c28aa773d075b550def4a93a5f9d3eec5775369162cae6f0061c1e1c22590f07aa29b644f5027 disable-test-layout.patch"
+e3d819bb29b3b6fc849a1e6b6413c21dd89386d54ddf44d6598c28aa773d075b550def4a93a5f9d3eec5775369162cae6f0061c1e1c22590f07aa29b644f5027 disable-test-layout.patch
+24f46b5d14dd589b0d5ca992169fb46a696d0251c63cf3c0210bfded534f4f35d20bcd158c4397d6ebe828ae995a5321daca4ecc634f0d5f38bc7f5ccf8f2fee CVE-2019-1010238.patch"
diff --git a/main/pango/CVE-2019-1010238.patch b/main/pango/CVE-2019-1010238.patch
new file mode 100644
index 0000000000..eaf0784c1b
--- /dev/null
+++ b/main/pango/CVE-2019-1010238.patch
@@ -0,0 +1,34 @@
+From 490f8979a260c16b1df055eab386345da18a2d54 Mon Sep 17 00:00:00 2001
+From: Matthias Clasen <mclasen@redhat.com>
+Date: Wed, 10 Jul 2019 20:26:23 -0400
+Subject: [PATCH] bidi: Be safer against bad input
+
+Don't run off the end of an array that we
+allocated to certain length.
+
+Closes: https://gitlab.gnome.org/GNOME/pango/issues/342
+---
+ pango/pango-bidi-type.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/pango/pango-bidi-type.c b/pango/pango-bidi-type.c
+index 3e46b66c..5c02dbbb 100644
+--- a/pango/pango-bidi-type.c
++++ b/pango/pango-bidi-type.c
+@@ -181,8 +181,11 @@ pango_log2vis_get_embedding_levels (const gchar *text,
+ for (i = 0, p = text; p < text + length; p = g_utf8_next_char(p), i++)
+ {
+ gunichar ch = g_utf8_get_char (p);
+- FriBidiCharType char_type;
+- char_type = fribidi_get_bidi_type (ch);
++ FriBidiCharType char_type = fribidi_get_bidi_type (ch);
++
++ if (i == n_chars)
++ break;
++
+ bidi_types[i] = char_type;
+ ored_types |= char_type;
+ if (FRIBIDI_IS_STRONG (char_type))
+--
+2.21.0
+