Vulnerabilities > CVE-2007-5795 - Local Variable Handling Code Execution vulnerability in GNU Emacs

047910
CVSS 6.3 - MEDIUM
Attack vector
LOCAL
Attack complexity
MEDIUM
Privileges required
NONE
Confidentiality impact
NONE
Integrity impact
COMPLETE
Availability impact
COMPLETE
local
debian
gnu
nessus
exploit available

Summary

The hack-local-variables function in Emacs before 22.2, when enable-local-variables is set to :safe, does not properly search lists of unsafe or risky variables, which might allow user-assisted attackers to bypass intended restrictions and modify critical program variables via a file containing a Local variables declaration.

Exploit-Db

descriptionGNU Emacs 22.1 Local Variable Handling Code Execution Vulnerability. CVE-2007-5795. Remote exploit for linux platform
idEDB-ID:30736
last seen2016-02-03
modified2007-11-02
published2007-11-02
reporterDrake Wilson
sourcehttps://www.exploit-db.com/download/30736/
titleGNU Emacs 22.1 - Local Variable Handling Code Execution Vulnerability

Nessus

  • NASL familyFedora Local Security Checks
    NASL idFEDORA_2007-2946.NASL
    description - Tue Nov 6 2007 Chip Coldwell <coldwell at redhat.com> 22.1-8 - fix insufficient safe-mode checks (Resolves: bz367591) - Thu Nov 1 2007 Chip Coldwell <coldwell at redhat.com> 22.1-7 - Update rpm-spec-mode to the current upstream, drop compat patch (bz306841) Note that Tenable Network Security has extracted the preceding description block directly from the Fedora security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen2020-06-01
    modified2020-06-02
    plugin id28254
    published2007-11-20
    reporterThis script is Copyright (C) 2007-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/28254
    titleFedora 8 : emacs-22.1-8.fc8 (2007-2946)
  • NASL familyGentoo Local Security Checks
    NASL idGENTOO_GLSA-200712-03.NASL
    descriptionThe remote host is affected by the vulnerability described in GLSA-200712-03 (GNU Emacs: Multiple vulnerabilities) Drake Wilson reported that the hack-local-variables() function in GNU Emacs 22 does not properly match assignments of local variables in a file against a list of unsafe or risky variables, allowing to override them (CVE-2007-5795). Andreas Schwab (SUSE) discovered a stack-based buffer overflow in the format function when handling values with high precision (CVE-2007-6109). Impact : Remote attackers could entice a user to open a specially crafted file in GNU Emacs, possibly leading to the execution of arbitrary Emacs Lisp code (via CVE-2007-5795) or arbitrary code (via CVE-2007-6109) with the privileges of the user running GNU Emacs. Workaround : The first vulnerability can be worked around by setting the
    last seen2020-06-01
    modified2020-06-02
    plugin id29290
    published2007-12-11
    reporterThis script is Copyright (C) 2007-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/29290
    titleGLSA-200712-03 : GNU Emacs: Multiple vulnerabilities
  • NASL familyFedora Local Security Checks
    NASL idFEDORA_2007-3056.NASL
    description - Tue Nov 6 2007 Chip Coldwell <coldwell at redhat.com> - 22.1-5 - fix insufficient safe-mode checks (Resolves: bz367581) - Update rpm-spec-mode to the current upstream, drop compat patch (bz306841) - Wed Sep 12 2007 Chip Coldwell <coldwell at redhat.com> - 22.1-4 - require xorg-x11-fonts-ISO8859-1-100dpi instead of 75dpi (Resolves: bz281861) - drop broken python mode (Resolves: bz262801) - use macro instead of variable style for buildroot. - add pkgconfig file. - Mon Aug 13 2007 Chip Coldwell <coldwell at redhat.com> - 22.1-3 - add pkgconfig file for emacs-common and virtual provides (Resolves: bz242176) - glibc-open-macro.patch to deal with glibc turning
    last seen2020-06-01
    modified2020-06-02
    plugin id28255
    published2007-11-20
    reporterThis script is Copyright (C) 2007-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/28255
    titleFedora 7 : emacs-22.1-5.fc7 (2007-3056)
  • NASL familyMacOS X Local Security Checks
    NASL idMACOSX_SECUPD2008-002.NASL
    descriptionThe remote host is running a version of Mac OS X 10.5 or 10.4 that does not have the security update 2008-002 applied. This update contains several security fixes for a number of programs.
    last seen2020-06-01
    modified2020-06-02
    plugin id31605
    published2008-03-19
    reporterThis script is Copyright (C) 2008-2018 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/31605
    titleMac OS X Multiple Vulnerabilities (Security Update 2008-002)
  • NASL familyMandriva Local Security Checks
    NASL idMANDRIVA_MDVSA-2008-034.NASL
    descriptionThe hack-local-variable function in Emacs 22 prior to version 22.2, when enable-local-variables is set to
    last seen2020-06-01
    modified2020-06-02
    plugin id36420
    published2009-04-23
    reporterThis script is Copyright (C) 2009-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/36420
    titleMandriva Linux Security Advisory : emacs (MDVSA-2008:034)
  • NASL familySuSE Local Security Checks
    NASL idSUSE_EMACS-4620.NASL
    descriptionThe setting
    last seen2020-06-01
    modified2020-06-02
    plugin id27647
    published2007-11-06
    reporterThis script is Copyright (C) 2007-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/27647
    titleopenSUSE 10 Security Update : emacs (emacs-4620)
  • NASL familyUbuntu Local Security Checks
    NASL idUBUNTU_USN-541-1.NASL
    descriptionDrake Wilson discovered that Emacs did not correctly handle the safe mode of
    last seen2020-06-01
    modified2020-06-02
    plugin id28209
    published2007-11-14
    reporterUbuntu Security Notice (C) 2007-2019 Canonical, Inc. / NASL script (C) 2018 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/28209
    titleUbuntu 7.10 : emacs22 vulnerability (USN-541-1)

Statements

contributorMark J Cox
lastmodified2007-11-09
organizationRed Hat
statementNot vulnerable. This issue did not affect versions of Emacs as shipped with Red Hat Enterprise Linux 2.1, 3, 4, or 5.