diff options
author | Leo Famulari <leo@famulari.name> | 2016-12-07 18:51:27 -0500 |
---|---|---|
committer | Leo Famulari <leo@famulari.name> | 2016-12-08 13:53:36 -0500 |
commit | 57513498def74f8d95ef10df654d28e5a638a612 (patch) | |
tree | 8d9cacc02fe22acb12b0f9ff919718d595e4e3ad /gnu/packages/patches | |
parent | a2c1dceadd2bf86ab17c70cd674bc98aec32a842 (diff) | |
download | guix-57513498def74f8d95ef10df654d28e5a638a612.tar guix-57513498def74f8d95ef10df654d28e5a638a612.tar.gz |
gnu: tcsh: Fix out of bounds read.
* gnu/packages/patches/tcsh-fix-out-of-bounds-read.patch: New file.
* gnu/local.mk (dist_patch_DATA): Add it.
* gnu/packages/shells.scm (tcsh)[replacement]: New field.
(tcsh/fixed): New variable.
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r-- | gnu/packages/patches/tcsh-fix-out-of-bounds-read.patch | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/gnu/packages/patches/tcsh-fix-out-of-bounds-read.patch b/gnu/packages/patches/tcsh-fix-out-of-bounds-read.patch new file mode 100644 index 0000000000..48c294f78e --- /dev/null +++ b/gnu/packages/patches/tcsh-fix-out-of-bounds-read.patch @@ -0,0 +1,31 @@ +Fix out-of-bounds read in c_substitute(): + +http://seclists.org/oss-sec/2016/q4/612 + +Patch copied from upstream source repository: + +https://github.com/tcsh-org/tcsh/commit/6a542dc4fb2ba26518a47e9b3a9bcd6a91b94596 + +From 6a542dc4fb2ba26518a47e9b3a9bcd6a91b94596 Mon Sep 17 00:00:00 2001 +From: christos <christos> +Date: Fri, 2 Dec 2016 16:59:28 +0000 +Subject: [PATCH] Fix out of bounds read (Brooks Davis) (reproduce by starting + tcsh and hitting tab at the prompt) + +--- + ed.chared.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/ed.chared.c b/ed.chared.c +index 1277e53..310393e 100644 +--- ed.chared.c ++++ ed.chared.c +@@ -750,7 +750,7 @@ c_substitute(void) + /* + * If we found a history character, go expand it. + */ +- if (HIST != '\0' && *p == HIST) ++ if (p >= InputBuf && HIST != '\0' && *p == HIST) + nr_exp = c_excl(p); + else + nr_exp = 0; |