]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
bash: Import upstream patches for CVE-2014-6271 and CVE-2014-7169
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 26 Sep 2014 10:42:27 +0000 (12:42 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 26 Sep 2014 10:42:27 +0000 (12:42 +0200)
config/rootfiles/core/84/filelists/bash [new symlink]
lfs/bash
src/patches/bash-3.2-CVE-2014-7169.patch [deleted file]
src/patches/bash/bash32-052 [moved from src/patches/bash-3.2-CVE-2014-6271.patch with 75% similarity]
src/patches/bash/bash32-053 [new file with mode: 0644]

diff --git a/config/rootfiles/core/84/filelists/bash b/config/rootfiles/core/84/filelists/bash
new file mode 120000 (symlink)
index 0000000..de970cb
--- /dev/null
@@ -0,0 +1 @@
+../../../common/bash
\ No newline at end of file
index 58556faf0448ff3bb7f8bbc7839de6cd94a9f332..55afd24ef2900fce7c1ce4dcf465edac715e6682 100644 (file)
--- a/lfs/bash
+++ b/lfs/bash
@@ -89,15 +89,13 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        @$(PREBUILD)
        @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar zxf $(DIR_DL)/$(DL_FILE)
 
-       for i in $$(seq 1 51); do \
+       for i in $$(seq 1 53); do \
                cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/bash/bash32-$$(printf "%03d" "$${i}") || exit 1; \
        done
 
        cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/bash-4.0-paths-1.patch
        cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/bash-4.0-profile-1.patch
        cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/bash-3.2-ssh_source_bash.patch
-       cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/bash-3.2-CVE-2014-6271.patch
-       cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/bash-3.2-CVE-2014-7169.patch
 
        cd $(DIR_APP) && ./configure $(EXTRA_CONFIG)
        cd $(DIR_APP) && make $(EXTRA_MAKE)
diff --git a/src/patches/bash-3.2-CVE-2014-7169.patch b/src/patches/bash-3.2-CVE-2014-7169.patch
deleted file mode 100644 (file)
index 964b91f..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-*** ../bash-20140912/parse.y   2014-08-26 15:09:42.000000000 -0400
---- parse.y    2014-09-24 22:47:28.000000000 -0400
-***************
-*** 2959,2962 ****
---- 2959,2964 ----
-    word_desc_to_read = (WORD_DESC *)NULL;
-  
-+   eol_ungetc_lookahead = 0;
-+ 
-    current_token = '\n';              /* XXX */
-    last_read_token = '\n';
similarity index 75%
rename from src/patches/bash-3.2-CVE-2014-6271.patch
rename to src/patches/bash/bash32-052
index 396491603ea01bc6f2440c814ceb57097d84f67e..78e7d92706b2fb9f7c0e882815c370e3ea555a8e 100644 (file)
@@ -1,3 +1,20 @@
+                            BASH PATCH REPORT
+                            =================
+
+Bash-Release: 3.2
+Patch-ID: bash32-052
+
+Bug-Reported-by:       Stephane Chazelas <stephane.chazelas@gmail.com>
+Bug-Reference-ID:
+Bug-Reference-URL:
+
+Bug-Description:
+
+Under certain circumstances, bash will execute user code while processing the
+environment for exported function definitions.
+
+Patch (apply with `patch -p0'):
+
 *** ../bash-3.2.51/builtins/common.h   2006-03-06 09:38:44.000000000 -0500
 --- builtins/common.h  2014-09-16 19:08:02.000000000 -0400
 ***************
        }
   #if defined (ARRAY_VARS)
 --- 331,334 ----
+*** ../bash-3.2/patchlevel.h   Thu Apr 13 08:31:04 2006
+--- patchlevel.h       Mon Oct 16 14:22:54 2006
+***************
+*** 26,30 ****
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 51
+  
+  #endif /* _PATCHLEVEL_H_ */
+--- 26,30 ----
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 52
+  
+  #endif /* _PATCHLEVEL_H_ */
diff --git a/src/patches/bash/bash32-053 b/src/patches/bash/bash32-053
new file mode 100644 (file)
index 0000000..e7efce7
--- /dev/null
@@ -0,0 +1,54 @@
+                            BASH PATCH REPORT
+                            =================
+
+Bash-Release: 3.2
+Patch-ID: bash32-053
+
+Bug-Reported-by:       Tavis Ormandy <taviso () cmpxchg8b com>
+Bug-Reference-ID:
+Bug-Reference-URL:     http://twitter.com/taviso/statuses/514887394294652929
+
+Bug-Description:
+
+Under certain circumstances, bash can incorrectly save a lookahead character and
+return it on a subsequent call, even when reading a new line.
+
+Patch:
+
+*** ../bash-3.2.52/parse.y     2008-04-29 21:24:55.000000000 -0400
+--- parse.y    2014-09-25 16:18:41.000000000 -0400
+***************
+*** 2504,2507 ****
+--- 2504,2509 ----
+    word_desc_to_read = (WORD_DESC *)NULL;
+  
++   eol_ungetc_lookahead = 0;
++ 
+    last_read_token = '\n';
+    token_to_read = '\n';
+*** ../bash-3.2.52/y.tab.c     2006-09-25 08:15:16.000000000 -0400
+--- y.tab.c    2014-09-25 20:28:17.000000000 -0400
+***************
+*** 3833,3836 ****
+--- 3833,3838 ----
+    word_desc_to_read = (WORD_DESC *)NULL;
+  
++   eol_ungetc_lookahead = 0;
++ 
+    last_read_token = '\n';
+    token_to_read = '\n';
+*** ../bash-3.2/patchlevel.h   Thu Apr 13 08:31:04 2006
+--- patchlevel.h       Mon Oct 16 14:22:54 2006
+***************
+*** 26,30 ****
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 52
+  
+  #endif /* _PATCHLEVEL_H_ */
+--- 26,30 ----
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 53
+  
+  #endif /* _PATCHLEVEL_H_ */