diff --git a/coreutils-i18n.patch b/coreutils-i18n.patch index 948b555..90d2063 100644 --- a/coreutils-i18n.patch +++ b/coreutils-i18n.patch @@ -3132,7 +3132,7 @@ diff -urNp coreutils-8.23-orig/src/sort.c coreutils-8.23/src/sort.c else if (key->random) diff = compare_random (ta, tlena, tb, tlenb); else if (key->version) -@@ -2695,6 +3135,209 @@ keycompare (struct line const *a, struct +@@ -2694,6 +3134,211 @@ keycompare (struct line const *a, struct return key->reverse ? -diff : diff; } @@ -3245,7 +3245,9 @@ diff -urNp coreutils-8.23-orig/src/sort.c coreutils-8.23/src/sort.c + + if (ignore || translate) + { -+ char *copy_a = (char *) xmalloc ((lena + lenb) * MB_CUR_MAX + 2); ++ if (SIZE_MAX - lenb - 2 < lena) ++ xalloc_die (); ++ char *copy_a = (char *) xnmalloc (lena + lenb + 2, MB_CUR_MAX); + char *copy_b = copy_a + lena * MB_CUR_MAX + 1; + size_t new_len_a, new_len_b; + size_t i, j; diff --git a/coreutils.spec b/coreutils.spec index 61adf85..7c691cb 100644 --- a/coreutils.spec +++ b/coreutils.spec @@ -374,6 +374,7 @@ fi %changelog * Wed Sep 16 2015 Kamil Dudka - 8.23-11 +- use newer version of sort/I18N fix for CVE-2015-4041 and CVE-2015-4042 - call utilities in colorls.* scripts with full path (#1222140) * Wed May 13 2015 Ondrej Oprala - 8.23-10