Vulnerabilities > CVE-2007-2692 - Privilege Escalation vulnerability in MySQL Security Invoker
Attack vector
NETWORK Attack complexity
MEDIUM Privileges required
SINGLE Confidentiality impact
PARTIAL Integrity impact
PARTIAL Availability impact
PARTIAL Summary
The mysql_change_db function in MySQL 5.0.x before 5.0.40 and 5.1.x before 5.1.18 does not restore THD::db_access privileges when returning from SQL SECURITY INVOKER stored routines, which allows remote authenticated users to gain privileges.
Vulnerable Configurations
Nessus
NASL family Ubuntu Local Security Checks NASL id UBUNTU_USN-588-1.NASL description Masaaki Hirose discovered that MySQL could be made to dereference a NULL pointer. An authenticated user could cause a denial of service (application crash) via an EXPLAIN SELECT FROM on the INFORMATION_SCHEMA table. This issue only affects Ubuntu 6.06 and 6.10. (CVE-2006-7232) Alexander Nozdrin discovered that MySQL did not restore database access privileges when returning from SQL SECURITY INVOKER stored routines. An authenticated user could exploit this to gain privileges. This issue does not affect Ubuntu 7.10. (CVE-2007-2692) Martin Friebe discovered that MySQL did not properly update the DEFINER value of an altered view. An authenticated user could use CREATE SQL SECURITY DEFINER VIEW and ALTER VIEW statements to gain privileges. (CVE-2007-6303) Luigi Auriemma discovered that yaSSL as included in MySQL did not properly validate its input. A remote attacker could send crafted requests and cause a denial of service or possibly execute arbitrary code. This issue did not affect Ubuntu 6.06 in the default installation. (CVE-2008-0226, CVE-2008-0227). Note that Tenable Network Security has extracted the preceding description block directly from the Ubuntu security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-01 modified 2020-06-02 plugin id 31638 published 2008-03-21 reporter Ubuntu Security Notice (C) 2008-2019 Canonical, Inc. / NASL script (C) 2018 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/31638 title Ubuntu 6.06 LTS / 6.10 / 7.04 / 7.10 : mysql-dfsg-5.0 vulnerabilities (USN-588-1) NASL family Databases NASL id MYSQL_5_1_18.NASL description The version of MySQL installed on the remote host reportedly is affected by several issues : - Evaluation of an last seen 2020-06-01 modified 2020-06-02 plugin id 25242 published 2007-05-17 reporter This script is Copyright (C) 2007-2018 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/25242 title MySQL 5.1 < 5.1.18 Multiple Vulnerabilities NASL family Databases NASL id MYSQL_SELECT_IF_DOS.NASL description The version of MySQL installed on the remote host reportedly is affected by a denial of service vulnerability that may be triggered with a specially crafted IF query. An attacker who can execute arbitrary SELECT statements may be able to leverage this issue to crash the affected service. last seen 2020-06-01 modified 2020-06-02 plugin id 25198 published 2007-05-10 reporter This script is Copyright (C) 2007-2018 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/25198 title MySQL Crafted IF Clause Divide-by-zero NULL Dereference DoS NASL family Debian Local Security Checks NASL id DEBIAN_DSA-1413.NASL description Several vulnerabilities have been found in the MySQL database packages with implications ranging from unauthorized database modifications to remotely triggered server crashes. The Common Vulnerabilities and Exposures project identifies the following problems : - CVE-2007-2583 The in_decimal::set function in item_cmpfunc.cc in MySQL before 5.0.40 allows context-dependent attackers to cause a denial of service (crash) via a crafted IF clause that results in a divide-by-zero error and a NULL pointer dereference. (Affects source version 5.0.32.) - CVE-2007-2691 MySQL does not require the DROP privilege for RENAME TABLE statements, which allows remote authenticated users to rename arbitrary tables. (All supported versions affected.) - CVE-2007-2692 The mysql_change_db function does not restore THD::db_access privileges when returning from SQL SECURITY INVOKER stored routines, which allows remote authenticated users to gain privileges. (Affects source version 5.0.32.) - CVE-2007-3780 MySQL could be made to overflow a signed char during authentication. Remote attackers could use specially crafted authentication requests to cause a denial of service. (Upstream source versions 4.1.11a and 5.0.32 affected.) - CVE-2007-3782 Phil Anderton discovered that MySQL did not properly verify access privileges when accessing external tables. As a result, authenticated users could exploit this to obtain UPDATE privileges to external tables. (Affects source version 5.0.32.) - CVE-2007-5925 The convert_search_mode_to_innobase function in ha_innodb.cc in the InnoDB engine in MySQL 5.1.23-BK and earlier allows remote authenticated users to cause a denial of service (database crash) via a certain CONTAINS operation on an indexed column, which triggers an assertion error. (Affects source version 5.0.32.) last seen 2020-06-01 modified 2020-06-02 plugin id 28336 published 2007-11-29 reporter This script is Copyright (C) 2007-2019 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/28336 title Debian DSA-1413-1 : mysql - multiple vulnerabilities NASL family Ubuntu Local Security Checks NASL id UBUNTU_USN-588-2.NASL description USN-588-1 fixed vulnerabilities in MySQL. In fixing CVE-2007-2692 for Ubuntu 6.06, additional improvements were made to make privilege checks more restictive. As a result, an upstream bug was exposed which could cause operations on tables or views in a different database to fail. This update fixes the problem. We apologize for the inconvenience. Masaaki Hirose discovered that MySQL could be made to dereference a NULL pointer. An authenticated user could cause a denial of service (application crash) via an EXPLAIN SELECT FROM on the INFORMATION_SCHEMA table. This issue only affects Ubuntu 6.06 and 6.10. (CVE-2006-7232) Alexander Nozdrin discovered that MySQL did not restore database access privileges when returning from SQL SECURITY INVOKER stored routines. An authenticated user could exploit this to gain privileges. This issue does not affect Ubuntu 7.10. (CVE-2007-2692) Martin Friebe discovered that MySQL did not properly update the DEFINER value of an altered view. An authenticated user could use CREATE SQL SECURITY DEFINER VIEW and ALTER VIEW statements to gain privileges. (CVE-2007-6303) Luigi Auriemma discovered that yaSSL as included in MySQL did not properly validate its input. A remote attacker could send crafted requests and cause a denial of service or possibly execute arbitrary code. This issue did not affect Ubuntu 6.06 in the default installation. (CVE-2008-0226, CVE-2008-0227). Note that Tenable Network Security has extracted the preceding description block directly from the Ubuntu security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues. last seen 2020-06-01 modified 2020-06-02 plugin id 31783 published 2008-04-04 reporter Ubuntu Security Notice (C) 2008-2019 Canonical, Inc. / NASL script (C) 2018 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/31783 title Ubuntu 6.06 LTS : mysql-dfsg-5.0 regression (USN-588-2) NASL family Mandriva Local Security Checks NASL id MANDRAKE_MDKSA-2007-177.NASL description A vulnerability was found in MySQL last seen 2020-06-01 modified 2020-06-02 plugin id 26009 published 2007-09-07 reporter This script is Copyright (C) 2007-2019 Tenable Network Security, Inc. source https://www.tenable.com/plugins/nessus/26009 title Mandrake Linux Security Advisory : MySQL (MDKSA-2007:177) NASL family Scientific Linux Local Security Checks NASL id SL_20080521_MYSQL_ON_SL5_X.NASL description MySQL did not require privileges such as last seen 2020-06-01 modified 2020-06-02 plugin id 60406 published 2012-08-01 reporter This script is Copyright (C) 2012-2019 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/60406 title Scientific Linux Security Update : mysql on SL5.x i386/x86_64 NASL family SuSE Local Security Checks NASL id SUSE_MYSQL-4879.NASL description This update fixes several security vulnerabilities (note: not all versions are affected by every bug) : - CVE-2007-2583 - CVE-2007-2691 - CVE-2007-2692 - CVE-2007-5925 - CVE-2007-5969 - CVE-2007-6303 - CVE-2007-6304 last seen 2020-06-01 modified 2020-06-02 plugin id 30182 published 2008-02-05 reporter This script is Copyright (C) 2008-2019 Tenable Network Security, Inc. source https://www.tenable.com/plugins/nessus/30182 title SuSE 10 Security Update : MySQL (ZYPP Patch Number 4879) NASL family Mandriva Local Security Checks NASL id MANDRIVA_MDVSA-2008-028.NASL description The mysql_change_db() function in MySQL 5.0.x before 5.0.40 did not restore THD::db_access privileges when returning from SQL SECURITY INVOKER stored routines, which allowed remote authenticated users to gain privileges (CVE-2007-2692). The federated engine in MySQL 5.0.x, when performing a certain SHOW TABLE STATUS query, did not properly handle a response with a small number of columns, which could allow a remote MySQL server to cause a denial of service (federated handler crash and daemon crash) via a response that lacks the minimum required number of columns (CVE-2007-6304). The updated packages provide MySQL 5.0.45 for all Mandriva Linux platforms that shipped with MySQL 5.0.x which offers a number of feature enhancements and bug fixes. In addition, the updates for Corporate Server 4.0 include support for the Sphinx engine. Please note that due to the package name change (from last seen 2020-06-01 modified 2020-06-02 plugin id 36399 published 2009-04-23 reporter This script is Copyright (C) 2009-2019 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/36399 title Mandriva Linux Security Advisory : mysql (MDVSA-2008:028) NASL family Databases NASL id MYSQL_5_0_40.NASL description The version of MySQL installed on the remote host is reportedly affected by several issues : - Evaluation of an last seen 2020-06-01 modified 2020-06-02 plugin id 17832 published 2012-01-18 reporter This script is Copyright (C) 2012-2018 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/17832 title MySQL 5.0 < 5.0.40 Multiple Vulnerabilities NASL family Red Hat Local Security Checks NASL id REDHAT-RHSA-2008-0364.NASL description Updated mysql packages that fix various security issues and several bugs are now available for Red Hat Enterprise Linux 5. This update has been rated as having low security impact by the Red Hat Security Response Team. MySQL is a multi-user, multi-threaded SQL database server. MySQL is a client/server implementation consisting of a server daemon (mysqld), and many different client programs and libraries. MySQL did not require privileges such as last seen 2020-06-01 modified 2020-06-02 plugin id 32425 published 2008-05-22 reporter This script is Copyright (C) 2008-2019 and is owned by Tenable, Inc. or an Affiliate thereof. source https://www.tenable.com/plugins/nessus/32425 title RHEL 5 : mysql (RHSA-2008:0364) NASL family SuSE Local Security Checks NASL id SUSE9_12044.NASL description This update fixes several security vulnerabilities (note: not all versions are affected by every bug) : - CVE-2007-2583 - CVE-2007-2691 - CVE-2007-2692 - CVE-2007-5925 - CVE-2007-5969 - CVE-2007-6303 - CVE-2007-6304 last seen 2020-06-01 modified 2020-06-02 plugin id 41184 published 2009-09-24 reporter This script is Copyright (C) 2009-2019 Tenable Network Security, Inc. source https://www.tenable.com/plugins/nessus/41184 title SuSE9 Security Update : MySQL (YOU Patch Number 12044) NASL family SuSE Local Security Checks NASL id SUSE_LIBMYSQLCLIENT-DEVEL-4873.NASL description This update fixes several security vulnerabilities (note: not all versions are affected by every bug) : - CVE-2007-2583 - CVE-2007-2691 - CVE-2007-2692 - CVE-2007-5925 - CVE-2007-5969 - CVE-2007-6303 - CVE-2007-6304 last seen 2020-06-01 modified 2020-06-02 plugin id 30180 published 2008-02-05 reporter This script is Copyright (C) 2008-2019 Tenable Network Security, Inc. source https://www.tenable.com/plugins/nessus/30180 title openSUSE 10 Security Update : libmysqlclient-devel (libmysqlclient-devel-4873)
Oval
accepted | 2013-04-29T04:18:24.000-04:00 | ||||||||||||
class | vulnerability | ||||||||||||
contributors |
| ||||||||||||
definition_extensions |
| ||||||||||||
description | The mysql_change_db function in MySQL 5.0.x before 5.0.40 and 5.1.x before 5.1.18 does not restore THD::db_access privileges when returning from SQL SECURITY INVOKER stored routines, which allows remote authenticated users to gain privileges. | ||||||||||||
family | unix | ||||||||||||
id | oval:org.mitre.oval:def:9166 | ||||||||||||
status | accepted | ||||||||||||
submitted | 2010-07-09T03:56:16-04:00 | ||||||||||||
title | The mysql_change_db function in MySQL 5.0.x before 5.0.40 and 5.1.x before 5.1.18 does not restore THD::db_access privileges when returning from SQL SECURITY INVOKER stored routines, which allows remote authenticated users to gain privileges. | ||||||||||||
version | 18 |
Redhat
advisories |
| ||||||||
rpms |
|
Statements
contributor | Joshua Bressers |
lastmodified | 2008-07-25 |
organization | Red Hat |
statement | This issue did not affect mysql packages as shipped in Red Hat Enterprise Linux 2.1, 3 and 4. Affected mysql packages as shipped in Red Hat Enterprise Linux 5 and Red Hat Application Stack were fixed via: https://rhn.redhat.com/errata/CVE-2007-2692.html |
References
- http://bugs.mysql.com/bug.php?id=27337
- http://dev.mysql.com/doc/refman/5.1/en/news-5-1-18.html
- http://lists.mysql.com/announce/470
- http://lists.opensuse.org/opensuse-security-announce/2008-02/msg00003.html
- http://osvdb.org/34765
- http://secunia.com/advisories/25301
- http://secunia.com/advisories/26073
- http://secunia.com/advisories/26430
- http://secunia.com/advisories/27823
- http://secunia.com/advisories/28637
- http://secunia.com/advisories/28838
- http://secunia.com/advisories/29443
- http://secunia.com/advisories/30351
- http://www.debian.org/security/2007/dsa-1413
- http://www.mandriva.com/security/advisories?name=MDVSA-2008:028
- http://www.redhat.com/support/errata/RHSA-2007-0894.html
- http://www.redhat.com/support/errata/RHSA-2008-0364.html
- http://www.securityfocus.com/archive/1/473874/100/0/threaded
- http://www.securityfocus.com/bid/24011
- http://www.securitytracker.com/id?1018070
- http://www.ubuntu.com/usn/usn-588-1
- http://www.vupen.com/english/advisories/2007/1804
- https://exchange.xforce.ibmcloud.com/vulnerabilities/34348
- https://issues.rpath.com/browse/RPL-1536
- https://oval.cisecurity.org/repository/search/definition/oval%3Aorg.mitre.oval%3Adef%3A9166