summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarkd <markd@pkgsrc.org>2008-06-02 21:09:48 +0000
committermarkd <markd@pkgsrc.org>2008-06-02 21:09:48 +0000
commit4095df2122f4b9fa0a82410673457462f99e5c00 (patch)
treec06adf104469d60ffba14ced09f62d652023b458
parent5bf97261c2b25ef1981773f438c2f1d070ac7379 (diff)
downloadpkgsrc-4095df2122f4b9fa0a82410673457462f99e5c00.tar.gz
Fix for CVE-2008-2142, automatically loading and executing .flc files.
-rw-r--r--editors/emacs/Makefile5
-rw-r--r--editors/emacs/distinfo3
-rw-r--r--editors/emacs/patches/patch-aw32
3 files changed, 37 insertions, 3 deletions
diff --git a/editors/emacs/Makefile b/editors/emacs/Makefile
index 1bcfbb2ef02..055fbb12448 100644
--- a/editors/emacs/Makefile
+++ b/editors/emacs/Makefile
@@ -1,10 +1,10 @@
-# $NetBSD: Makefile,v 1.112 2008/05/06 02:34:39 jnemeth Exp $
+# $NetBSD: Makefile,v 1.113 2008/06/02 21:09:48 markd Exp $
PKGNAME?= ${DISTNAME}
COMMENT?= GNU editing macros (editor)
DISTNAME= emacs-22.1
-PKGREVISION= 4
+PKGREVISION= 5
CATEGORIES= editors
MASTER_SITES= ${MASTER_SITE_GNU:=emacs/}
@@ -63,6 +63,7 @@ post-extract:
# for patch-ac
post-build:
(cd ${WRKSRC}/lisp; ${MAKE_PROGRAM} files.elc)
+ (cd ${WRKSRC}/lisp; ${MAKE_PROGRAM} obsolete/fast-lock.elc)
touch ${WRKSRC}/etc/DOC
touch ${WRKSRC}/src/emacs
diff --git a/editors/emacs/distinfo b/editors/emacs/distinfo
index 5c022d1cfd9..36984fdca35 100644
--- a/editors/emacs/distinfo
+++ b/editors/emacs/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.36 2008/04/29 12:54:56 tonnerre Exp $
+$NetBSD: distinfo,v 1.37 2008/06/02 21:09:48 markd Exp $
SHA1 (emacs-22.1.tar.gz) = 327664173eabe5db49d4e7e4a4b1794577af902e
RMD160 (emacs-22.1.tar.gz) = da5360871db8b1d473ff7f0b0937ee6c278c0b19
@@ -21,4 +21,5 @@ SHA1 (patch-as) = 15ab1dcc2d6a445b119b7f2bb8a8331b4aa1fbd0
SHA1 (patch-at) = 470cbad6632038ff85aa942f74cab601e7f707fe
SHA1 (patch-au) = e5d90961b4d78c37dec196097a16e0b6ac22e3bb
SHA1 (patch-av) = 252f3085a1e4986a25b46afa74837ca0562f4f05
+SHA1 (patch-aw) = 456feb2517cad514837b75863336265006c158ee
SHA1 (patch-xx) = c486e9ca2c9134caf60ec935bf086e29324b1979
diff --git a/editors/emacs/patches/patch-aw b/editors/emacs/patches/patch-aw
new file mode 100644
index 00000000000..0550b65ec19
--- /dev/null
+++ b/editors/emacs/patches/patch-aw
@@ -0,0 +1,32 @@
+$NetBSD: patch-aw,v 1.4 2008/06/02 21:09:48 markd Exp $
+
+fix for CVE-2008-2142 from post 22.2 cvs.
+
+--- lisp/obsolete/fast-lock.el.orig 2007-01-21 16:53:09.000000000 +1300
++++ lisp/obsolete/fast-lock.el
+@@ -286,7 +286,7 @@ for buffers in Rmail mode, and size is i
+ (integer :tag "size")))))
+ :group 'fast-lock)
+
+-(defcustom fast-lock-cache-directories '("." "~/.emacs-flc")
++(defcustom fast-lock-cache-directories '("~/.emacs-flc")
+ ; - `internal', keep each file's Font Lock cache file in the same file.
+ ; - `external', keep each file's Font Lock cache file in the same directory.
+ "*Directories in which Font Lock cache files are saved and read.
+@@ -304,12 +304,15 @@ For example:
+ ((\"^/your/true/home/directory/\" . \".\") \"~/.emacs-flc\")
+
+ would cause a file's current directory to be used if the file is under your
+-home directory hierarchy, or otherwise the absolute directory `~/.emacs-flc'."
++home directory hierarchy, or otherwise the absolute directory `~/.emacs-flc'.
++For security reasons, it is not advisable to use the file's current directory
++to avoid the possibility of using the cache of another user."
+ :type '(repeat (radio (directory :tag "directory")
+ (cons :tag "Matching"
+ (regexp :tag "regexp")
+ (directory :tag "directory"))))
+ :group 'fast-lock)
++(put 'fast-lock-cache-directories 'risky-local-variable t)
+
+ (defcustom fast-lock-save-events '(kill-buffer kill-emacs)
+ "*Events under which caches will be saved.